use of com.hazelcast.simulator.coordinator.TestSuite in project hazelcast-simulator by hazelcast.
the class TestSuiteTest method testMaxCaseIdLength.
@Test
public void testMaxCaseIdLength() {
TestSuite testSuite = new TestSuite();
testSuite.addTest(new TestCase("abc"));
testSuite.addTest(new TestCase("88888888"));
testSuite.addTest(new TestCase("abcDEF"));
testSuite.addTest(new TestCase(""));
testSuite.addTest(new TestCase("four"));
assertEquals(8, testSuite.getMaxTestCaseIdLength());
}
use of com.hazelcast.simulator.coordinator.TestSuite in project hazelcast-simulator by hazelcast.
the class RegistryTest method testAddTests_testIdFixing.
@Test
public void testAddTests_testIdFixing() {
TestCase test1 = new TestCase("foo");
TestCase test2 = new TestCase("foo");
TestCase test3 = new TestCase("foo");
registry.addTests(new TestSuite().addTest(test1));
registry.addTests(new TestSuite().addTest(test2));
registry.addTests(new TestSuite().addTest(test3));
assertEquals("foo", test1.getId());
assertEquals("foo__1", test2.getId());
assertEquals("foo__2", test3.getId());
}
use of com.hazelcast.simulator.coordinator.TestSuite in project hazelcast-simulator by hazelcast.
the class RegistryTest method testAddTests.
@Test
public void testAddTests() {
TestSuite testSuite = new TestSuite();
testSuite.addTest(new TestCase("Test1"));
testSuite.addTest(new TestCase("Test2"));
testSuite.addTest(new TestCase("Test3"));
List<TestData> tests = registry.addTests(testSuite);
assertEquals(3, tests.size());
assertEquals(3, registry.testCount());
}
use of com.hazelcast.simulator.coordinator.TestSuite in project hazelcast-simulator by hazelcast.
the class TestSuiteTest method testConstructor.
@Test
public void testConstructor() {
TestSuite testSuite = new TestSuite();
assertTrue(testSuite.getTestCaseList().isEmpty());
assertEquals(0, testSuite.getMaxTestCaseIdLength());
}
use of com.hazelcast.simulator.coordinator.TestSuite in project hazelcast-simulator by hazelcast.
the class Runner method run.
public void run() throws Exception {
prepareClassPathForUploading();
Coordinator coordinator = newCoordinator();
try {
startMembers(coordinator);
startClients(coordinator);
TestSuite suite = newTestSuite();
coordinator.testRun(new RcTestRunOperation(suite));
} finally {
coordinator.close();
}
}
Aggregations