public void setUp() throws Exception { super.setUp(); deploymentSnapshots = null; totDeployed = 0; killedNode = 0; aliveNodes = null; }
public void setUp() throws Exception { super.setUp(); TestVerticle.instanceCount.set(0); }
@Override public void setUp() throws Exception { super.setUp(); eb = vertx.eventBus(); } }
@Override public void setUp() throws Exception { super.setUp(); eb = vertx.eventBus(); } }
@Override public void setUp() throws Exception { super.setUp(); resolver = new FileResolver(); }
public void setUp() throws Exception { super.setUp(); sharedData = vertx.sharedData(); }
public void setUp() throws Exception { super.setUp(); eb = vertx.eventBus(); }
@Override public void setUp() throws Exception { super.setUp(); TestVerticle.instanceCount.set(0); TestVerticle.processArgs = null; TestVerticle.conf = null; VertxCommandLauncher.resetProcessArguments(); File manifest = new File("target/test-classes/META-INF/MANIFEST-Starter.MF"); if (!manifest.isFile()) { throw new IllegalStateException("Cannot find the MANIFEST-Starter.MF file"); } File target = new File("target/test-classes/META-INF/MANIFEST.MF"); Files.copy(manifest.toPath(), target.toPath(), StandardCopyOption.REPLACE_EXISTING); }
public void setUp() throws Exception { super.setUp(); // Unregister the factory that's loaded from the classpath VerticleFactory factory = vertx.verticleFactories().iterator().next(); vertx.unregisterVerticleFactory(factory); }
public void setUp() throws Exception { super.setUp(); java.nio.file.FileSystem fs = FileSystems.getDefault(); pathSep = fs.getSeparator(); File ftestDir = testFolder.newFolder(); testDir = ftestDir.toString(); }
@Override public void setUp() throws Exception { super.setUp(); CountDownLatch listenLatch = new CountDownLatch(1); httpServer = vertx.createHttpServer() .requestHandler(request -> {}) .exceptionHandler(t -> { caught.set(t); resetLatch.countDown(); }) .listen(8080, onSuccess(server -> listenLatch.countDown())); awaitLatch(listenLatch); }
@Override public void setUp() throws Exception { dnsServer = new FakeDNSServer(); dnsServer.start(); super.setUp(); }
public void setUp() throws Exception { super.setUp(); client = vertx.createHttpClient(new HttpClientOptions()); }
@Override public void setUp() throws Exception { super.setUp(); context = vertx.getOrCreateContext(); sequence = new AtomicInteger(); context.runOnContext(v -> { Thread contextThread = Thread.currentThread(); contextChecker = () -> { assertSame(contextThread, Thread.currentThread()); }; }); waitUntil(() -> contextChecker != null); }
public void setUp() throws Exception { super.setUp(); server = vertx.createHttpServer(new HttpServerOptions().setPort(DEFAULT_HTTP_PORT).setHost(DEFAULT_HTTP_HOST)); }
@Override public void setUp() throws Exception { super.setUp(); startNodes(1); clusterManager = ((VertxInternal) vertices[0]).getClusterManager(); CountDownLatch latch = new CountDownLatch(1); clusterManager.<String, ServerID>getAsyncMultiMap("mymap", onSuccess(res -> { map = res; latch.countDown(); })); awaitLatch(latch); }
@Override public void setUp() throws Exception { dnsServer = new FakeDNSServer().testResolveASameServer("127.0.0.1"); dnsServer.start(); dnsServerAddress = dnsServer.localAddress(); super.setUp(); }
@Override public void setUp() throws Exception { dnsServer = new FakeDNSServer().testLookupNonExisting(); dnsServer.start(); dnsServerAddress = dnsServer.localAddress(); super.setUp(); }
public void setUp() throws Exception { super.setUp(); if (USE_DOMAIN_SOCKETS) { assertTrue("Native transport not enabled", USE_NATIVE_TRANSPORT); tmp = TestUtils.tmpFile(".sock"); testAddress = SocketAddress.domainSocketAddress(tmp.getAbsolutePath()); } else { testAddress = SocketAddress.inetSocketAddress(1234, "localhost"); } client = vertx.createNetClient(new NetClientOptions().setConnectTimeout(1000)); server = vertx.createNetServer(); }
@Override public void setUp() throws Exception { super.setUp(); randType = TestUtils.randomElement(ProxyType.values()); randHost = TestUtils.randomAlphaString(10); randPort = TestUtils.randomPortInt(); randUsername = TestUtils.randomAlphaString(10); randPassword = TestUtils.randomAlphaString(10); }