http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridReleaseTypeSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridReleaseTypeSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridReleaseTypeSelfTest.java index b3e69a0..803f77f 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridReleaseTypeSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridReleaseTypeSelfTest.java @@ -27,10 +27,14 @@ import org.apache.ignite.spi.discovery.tcp.TcpDiscoverySpi; import org.apache.ignite.spi.discovery.tcp.ipfinder.TcpDiscoveryIpFinder; import org.apache.ignite.spi.discovery.tcp.ipfinder.vm.TcpDiscoveryVmIpFinder; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * Test grids starting with non compatible release types. */ +@RunWith(JUnit4.class) public class GridReleaseTypeSelfTest extends GridCommonAbstractTest { /** IP finder. */ private static final TcpDiscoveryIpFinder IP_FINDER = new TcpDiscoveryVmIpFinder(true); @@ -74,6 +78,7 @@ public class GridReleaseTypeSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testOsEditionDoesNotSupportRollingUpdates() throws Exception { nodeVer = "1.0.0"; @@ -101,6 +106,7 @@ public class GridReleaseTypeSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testOsEditionDoesNotSupportRollingUpdatesClientMode() throws Exception { nodeVer = "1.0.0"; @@ -125,4 +131,4 @@ public class GridReleaseTypeSelfTest extends GridCommonAbstractTest { throw e; } } -} \ No newline at end of file +}
http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridRuntimeExceptionSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridRuntimeExceptionSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridRuntimeExceptionSelfTest.java index a1f946b..c5ad9ad 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridRuntimeExceptionSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridRuntimeExceptionSelfTest.java @@ -40,6 +40,9 @@ import org.apache.ignite.resources.IgniteInstanceResource; import org.apache.ignite.resources.LoggerResource; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.apache.ignite.testframework.junits.common.GridCommonTest; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; import static org.apache.ignite.events.EventType.EVT_TASK_FAILED; @@ -48,6 +51,7 @@ import static org.apache.ignite.events.EventType.EVT_TASK_FAILED; */ @SuppressWarnings({"ProhibitedExceptionDeclared"}) @GridCommonTest(group = "Kernal Self") +@RunWith(JUnit4.class) public class GridRuntimeExceptionSelfTest extends GridCommonAbstractTest { /** */ private enum FailType { @@ -77,6 +81,7 @@ public class GridRuntimeExceptionSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testExecuteFailed() throws Exception { Ignite ignite = G.ignite(getTestIgniteInstanceName()); @@ -107,6 +112,7 @@ public class GridRuntimeExceptionSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testMapFailed() throws Exception { Ignite ignite = G.ignite(getTestIgniteInstanceName()); @@ -137,6 +143,7 @@ public class GridRuntimeExceptionSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testResultFailed() throws Exception { Ignite ignite = G.ignite(getTestIgniteInstanceName()); @@ -167,6 +174,7 @@ public class GridRuntimeExceptionSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testReduceFailed() throws Exception { Ignite ignite = G.ignite(getTestIgniteInstanceName()); @@ -305,4 +313,4 @@ public class GridRuntimeExceptionSelfTest extends GridCommonAbstractTest { return true; } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridSameVmStartupSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridSameVmStartupSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridSameVmStartupSelfTest.java index a04c38e..9b7cdfc 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridSameVmStartupSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridSameVmStartupSelfTest.java @@ -29,6 +29,9 @@ import org.apache.ignite.internal.util.typedef.G; import org.apache.ignite.lang.IgnitePredicate; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.apache.ignite.testframework.junits.common.GridCommonTest; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; import static org.apache.ignite.events.EventType.EVTS_DISCOVERY; import static org.apache.ignite.events.EventType.EVT_NODE_FAILED; @@ -40,6 +43,7 @@ import static org.apache.ignite.events.EventType.EVT_NODE_METRICS_UPDATED; * events while stopping one them. */ @GridCommonTest(group = "Kernal Self") +@RunWith(JUnit4.class) public class GridSameVmStartupSelfTest extends GridCommonAbstractTest { /** * @@ -53,6 +57,7 @@ public class GridSameVmStartupSelfTest extends GridCommonAbstractTest { * * @throws Exception If failed. */ + @Test public void testSameVmStartup() throws Exception { Ignite ignite1 = startGrid(1); @@ -118,4 +123,4 @@ public class GridSameVmStartupSelfTest extends GridCommonAbstractTest { assert G.allGrids().isEmpty(); } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridSelfTest.java index 36d26d8..32b0e8a 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridSelfTest.java @@ -29,11 +29,15 @@ import org.apache.ignite.internal.util.typedef.P2; import org.apache.ignite.messaging.MessagingListenActor; import org.apache.ignite.testframework.GridTestUtils; import org.apache.ignite.testframework.junits.common.GridCommonTest; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * Test for {@link org.apache.ignite.IgniteCluster}. */ @GridCommonTest(group = "Kernal Self") +@RunWith(JUnit4.class) public class GridSelfTest extends ClusterGroupAbstractTest { /** Nodes count. */ private static final int NODES_CNT = 4; @@ -65,6 +69,7 @@ public class GridSelfTest extends ClusterGroupAbstractTest { } /** {@inheritDoc} */ + @Test @Override public void testRemoteNodes() throws Exception { int size = remoteNodeIds().size(); @@ -85,6 +90,7 @@ public class GridSelfTest extends ClusterGroupAbstractTest { } /** {@inheritDoc} */ + @Test @Override public void testRemoteProjection() throws Exception { ClusterGroup remotePrj = projection().forRemotes(); @@ -109,6 +115,7 @@ public class GridSelfTest extends ClusterGroupAbstractTest { /** * @throws Exception If failed. */ + @Test public void testAsyncListen() throws Exception { final String hello = "HELLO!"; @@ -154,6 +161,7 @@ public class GridSelfTest extends ClusterGroupAbstractTest { /** * @throws Exception If failed. */ + @Test public void testForOthers() throws Exception { ClusterNode node0 = grid(0).localNode(); ClusterNode node1 = grid(1).localNode(); @@ -170,4 +178,4 @@ public class GridSelfTest extends ClusterGroupAbstractTest { assertEquals(1, grid(0).cluster().forOthers(node1, node2, node3).nodes().size()); } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridSpiExceptionSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridSpiExceptionSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridSpiExceptionSelfTest.java index a588ce0..beef7a0 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridSpiExceptionSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridSpiExceptionSelfTest.java @@ -36,11 +36,15 @@ import org.apache.ignite.spi.eventstorage.EventStorageSpi; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.apache.ignite.testframework.junits.common.GridCommonTest; import org.jetbrains.annotations.Nullable; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * Tests exceptions that are thrown by event storage and deployment spi. */ @GridCommonTest(group = "Kernal Self") +@RunWith(JUnit4.class) public class GridSpiExceptionSelfTest extends GridCommonAbstractTest { /** */ private static final String TEST_MSG = "Test exception message"; @@ -66,6 +70,7 @@ public class GridSpiExceptionSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testSpiFail() throws Exception { Ignite ignite = startGrid(); @@ -182,4 +187,4 @@ public class GridSpiExceptionSelfTest extends GridCommonAbstractTest { super(msg, cause); } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridStartStopSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridStartStopSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridStartStopSelfTest.java index c596f74..1f664f7 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridStartStopSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridStartStopSelfTest.java @@ -34,6 +34,9 @@ import org.apache.ignite.testframework.GridTestUtils; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.apache.ignite.testframework.junits.common.GridCommonTest; import org.apache.ignite.transactions.Transaction; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; import static java.util.concurrent.TimeUnit.SECONDS; import static org.apache.ignite.IgniteSystemProperties.IGNITE_OVERRIDE_MCAST_GRP; @@ -46,6 +49,7 @@ import static org.apache.ignite.transactions.TransactionIsolation.REPEATABLE_REA */ @SuppressWarnings({"InstanceofCatchParameter"}) @GridCommonTest(group = "Kernal Self") +@RunWith(JUnit4.class) public class GridStartStopSelfTest extends GridCommonAbstractTest { /** */ public static final int COUNT = 1; @@ -57,6 +61,7 @@ public class GridStartStopSelfTest extends GridCommonAbstractTest { /** */ + @Test public void testStartStop() { IgniteConfiguration cfg = new IgniteConfiguration(); @@ -78,6 +83,7 @@ public class GridStartStopSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testStopWhileInUse() throws Exception { IgniteConfiguration cfg = new IgniteConfiguration(); @@ -145,6 +151,7 @@ public class GridStartStopSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testStoppedState() throws Exception { IgniteConfiguration cfg = new IgniteConfiguration(); @@ -218,4 +225,4 @@ public class GridStartStopSelfTest extends GridCommonAbstractTest { assertTrue(errs, errs == null || errs.isEmpty()); } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridStopWithCancelSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridStopWithCancelSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridStopWithCancelSelfTest.java index 5cc9e9b6..e621d88 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridStopWithCancelSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridStopWithCancelSelfTest.java @@ -33,11 +33,15 @@ import org.apache.ignite.resources.IgniteInstanceResource; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.apache.ignite.testframework.junits.common.GridCommonTest; import org.jetbrains.annotations.Nullable; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * Tests grid stop with jobs canceling. */ @GridCommonTest(group = "Kernal Self") +@RunWith(JUnit4.class) public class GridStopWithCancelSelfTest extends GridCommonAbstractTest { /** */ private static CountDownLatch cnt; @@ -60,6 +64,7 @@ public class GridStopWithCancelSelfTest extends GridCommonAbstractTest { /** * @throws Exception If an error occurs. */ + @Test public void testStopGrid() throws Exception { cancelCorrect = false; @@ -125,4 +130,4 @@ public class GridStopWithCancelSelfTest extends GridCommonAbstractTest { return null; } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridStopWithWaitSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridStopWithWaitSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridStopWithWaitSelfTest.java index dee0f1d..bb3e582 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridStopWithWaitSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridStopWithWaitSelfTest.java @@ -48,11 +48,15 @@ import org.apache.ignite.resources.TaskSessionResource; import org.apache.ignite.spi.failover.always.AlwaysFailoverSpi; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.apache.ignite.testframework.junits.common.GridCommonTest; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * Tests waiting for unfinished tasks while stopping the grid. */ @GridCommonTest(group = "Kernal Self") +@RunWith(JUnit4.class) public class GridStopWithWaitSelfTest extends GridCommonAbstractTest { /** Initial node that job has been mapped to. */ private static final AtomicReference<ClusterNode> nodeRef = new AtomicReference<>(null); @@ -79,6 +83,7 @@ public class GridStopWithWaitSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testWait() throws Exception { jobStarted = new CountDownLatch(1); @@ -113,6 +118,7 @@ public class GridStopWithWaitSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testWaitFailover() throws Exception { jobStarted = new CountDownLatch(1); @@ -278,4 +284,4 @@ public class GridStopWithWaitSelfTest extends GridCommonAbstractTest { return res.get(0).getData(); } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridTaskCancelSingleNodeSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskCancelSingleNodeSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskCancelSingleNodeSelfTest.java index 950f89d..22bfc7b 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskCancelSingleNodeSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskCancelSingleNodeSelfTest.java @@ -38,6 +38,9 @@ import org.apache.ignite.resources.IgniteInstanceResource; import org.apache.ignite.resources.LoggerResource; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.jetbrains.annotations.Nullable; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; import static org.apache.ignite.events.EventType.EVT_JOB_CANCELLED; import static org.apache.ignite.events.EventType.EVT_JOB_FINISHED; @@ -47,6 +50,7 @@ import static org.apache.ignite.events.EventType.EVT_JOB_STARTED; /** * Test for task cancellation issue. */ +@RunWith(JUnit4.class) public class GridTaskCancelSingleNodeSelfTest extends GridCommonAbstractTest { /** {@inheritDoc} */ @Override protected void beforeTest() throws Exception { @@ -61,6 +65,7 @@ public class GridTaskCancelSingleNodeSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testImmediateCancellation() throws Exception { checkCancellation(0L); } @@ -68,6 +73,7 @@ public class GridTaskCancelSingleNodeSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testCancellation() throws Exception { checkCancellation(2000L); } @@ -203,4 +209,4 @@ public class GridTaskCancelSingleNodeSelfTest extends GridCommonAbstractTest { return null; } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridTaskContinuousMapperSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskContinuousMapperSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskContinuousMapperSelfTest.java index a6f7f0e..c80a75f 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskContinuousMapperSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskContinuousMapperSelfTest.java @@ -38,15 +38,20 @@ import org.apache.ignite.resources.LoggerResource; import org.apache.ignite.resources.TaskContinuousMapperResource; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.apache.ignite.testframework.junits.common.GridCommonTest; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * {@link org.apache.ignite.compute.ComputeTaskContinuousMapper} test. */ @GridCommonTest(group = "Kernal Self") +@RunWith(JUnit4.class) public class GridTaskContinuousMapperSelfTest extends GridCommonAbstractTest { /** * @throws Exception If test failed. */ + @Test public void testContinuousMapperMethods() throws Exception { try { Ignite ignite = startGrid(0); @@ -63,6 +68,7 @@ public class GridTaskContinuousMapperSelfTest extends GridCommonAbstractTest { /** * @throws Exception If test failed. */ + @Test public void testContinuousMapperLifeCycle() throws Exception { try { Ignite ignite = startGrid(0); @@ -77,6 +83,7 @@ public class GridTaskContinuousMapperSelfTest extends GridCommonAbstractTest { /** * @throws Exception If test failed. */ + @Test public void testContinuousMapperNegative() throws Exception { try { Ignite ignite = startGrid(0); @@ -338,4 +345,4 @@ public class GridTaskContinuousMapperSelfTest extends GridCommonAbstractTest { return argument(0); } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridTaskExecutionContextSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskExecutionContextSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskExecutionContextSelfTest.java index c31c805..2f8ce1d 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskExecutionContextSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskExecutionContextSelfTest.java @@ -35,10 +35,14 @@ import org.apache.ignite.lang.IgniteRunnable; import org.apache.ignite.resources.TaskSessionResource; import org.apache.ignite.testframework.GridTestUtils; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * Tests for {@code GridProjection.withXXX(..)} methods. */ +@RunWith(JUnit4.class) public class GridTaskExecutionContextSelfTest extends GridCommonAbstractTest { /** */ private static final AtomicInteger CNT = new AtomicInteger(); @@ -56,6 +60,7 @@ public class GridTaskExecutionContextSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testWithName() throws Exception { IgniteCallable<String> f = new IgniteCallable<String>() { @TaskSessionResource @@ -80,6 +85,7 @@ public class GridTaskExecutionContextSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testWithNoFailoverClosure() throws Exception { final IgniteRunnable r = new GridAbsClosureX() { @Override public void applyx() { @@ -110,6 +116,7 @@ public class GridTaskExecutionContextSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testWithNoFailoverTask() throws Exception { final Ignite g = grid(0); @@ -165,4 +172,4 @@ public class GridTaskExecutionContextSelfTest extends GridCommonAbstractTest { return F.first(results).getData(); } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridTaskExecutionSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskExecutionSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskExecutionSelfTest.java index e197908..465a15d 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskExecutionSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskExecutionSelfTest.java @@ -33,11 +33,15 @@ import org.apache.ignite.lang.IgniteUuid; import org.apache.ignite.resources.JobContextResource; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.apache.ignite.testframework.junits.common.GridCommonTest; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * Task execution test. */ @GridCommonTest(group = "Kernal Self") +@RunWith(JUnit4.class) public class GridTaskExecutionSelfTest extends GridCommonAbstractTest { /** Grid instance. */ private Ignite ignite; @@ -78,6 +82,7 @@ public class GridTaskExecutionSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testSynchronousExecute() throws Exception { ComputeTaskFuture<?> fut = ignite.compute().executeAsync(GridTestTask.class, "testArg"); @@ -91,6 +96,7 @@ public class GridTaskExecutionSelfTest extends GridCommonAbstractTest { * * @throws Exception If failed. */ + @Test public void testJobIdCollision() throws Exception { fail("Test refactoring is needed: https://issues.apache.org/jira/browse/IGNITE-4706"); @@ -155,6 +161,7 @@ public class GridTaskExecutionSelfTest extends GridCommonAbstractTest { * * @throws Exception If failed. */ + @Test public void testExecuteTaskWithInvalidName() throws Exception { try { ComputeTaskFuture<?> fut = ignite.compute().execute("invalid.task.name", null); http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFailoverAffinityRunTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFailoverAffinityRunTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFailoverAffinityRunTest.java index 1358936..f1354b5 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFailoverAffinityRunTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFailoverAffinityRunTest.java @@ -33,6 +33,9 @@ import org.apache.ignite.spi.discovery.tcp.ipfinder.TcpDiscoveryIpFinder; import org.apache.ignite.spi.discovery.tcp.ipfinder.vm.TcpDiscoveryVmIpFinder; import org.apache.ignite.testframework.GridTestUtils; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; import static org.apache.ignite.cache.CacheAtomicityMode.ATOMIC; import static org.apache.ignite.cache.CacheMode.PARTITIONED; @@ -41,6 +44,7 @@ import static org.apache.ignite.cache.CacheRebalanceMode.SYNC; /** * */ +@RunWith(JUnit4.class) public class GridTaskFailoverAffinityRunTest extends GridCommonAbstractTest { /** */ private static TcpDiscoveryIpFinder ipFinder = new TcpDiscoveryVmIpFinder(true); @@ -86,6 +90,7 @@ public class GridTaskFailoverAffinityRunTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testNodeRestart() throws Exception { clientMode = false; @@ -95,6 +100,7 @@ public class GridTaskFailoverAffinityRunTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testNodeRestartClient() throws Exception { clientMode = true; @@ -169,4 +175,4 @@ public class GridTaskFailoverAffinityRunTest extends GridCommonAbstractTest { return null; } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFailoverSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFailoverSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFailoverSelfTest.java index bc0af82..101c5ad 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFailoverSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFailoverSelfTest.java @@ -32,11 +32,15 @@ import org.apache.ignite.compute.ComputeTaskSplitAdapter; import org.apache.ignite.resources.LoggerResource; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.apache.ignite.testframework.junits.common.GridCommonTest; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * Test for task failover. */ @GridCommonTest(group = "Kernal Self") +@RunWith(JUnit4.class) public class GridTaskFailoverSelfTest extends GridCommonAbstractTest { /** Don't change it value. */ public static final int SPLIT_COUNT = 2; @@ -49,6 +53,7 @@ public class GridTaskFailoverSelfTest extends GridCommonAbstractTest { /** * @throws Exception If test failed. */ + @Test public void testFailover() throws Exception { Ignite ignite = startGrid(); @@ -119,4 +124,4 @@ public class GridTaskFailoverSelfTest extends GridCommonAbstractTest { return res; } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFutureImplStopGridSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFutureImplStopGridSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFutureImplStopGridSelfTest.java index d522137..33661ec 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFutureImplStopGridSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFutureImplStopGridSelfTest.java @@ -38,11 +38,15 @@ import org.apache.ignite.lang.IgniteFuture; import org.apache.ignite.resources.LoggerResource; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.apache.ignite.testframework.junits.common.GridCommonTest; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * Test for task future when grid stops. */ @GridCommonTest(group = "Kernal Self") +@RunWith(JUnit4.class) public class GridTaskFutureImplStopGridSelfTest extends GridCommonAbstractTest { /** */ private static final int WAIT_TIME = 5000; @@ -67,6 +71,7 @@ public class GridTaskFutureImplStopGridSelfTest extends GridCommonAbstractTest { /** * @throws Exception If test failed. */ + @Test public void testGet() throws Exception { Ignite ignite = startGrid(getTestIgniteInstanceName()); @@ -218,4 +223,4 @@ public class GridTaskFutureImplStopGridSelfTest extends GridCommonAbstractTest { return !Thread.currentThread().isInterrupted() ? 0 : 1; } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridTaskInstanceExecutionSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskInstanceExecutionSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskInstanceExecutionSelfTest.java index 2f153bb..4bda431 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskInstanceExecutionSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskInstanceExecutionSelfTest.java @@ -30,12 +30,16 @@ import org.apache.ignite.internal.util.typedef.G; import org.apache.ignite.resources.LoggerResource; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.apache.ignite.testframework.junits.common.GridCommonTest; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * Task instance execution test. */ @SuppressWarnings("PublicInnerClass") @GridCommonTest(group = "Kernal Self") +@RunWith(JUnit4.class) public class GridTaskInstanceExecutionSelfTest extends GridCommonAbstractTest { /** */ private static Object testState; @@ -48,6 +52,7 @@ public class GridTaskInstanceExecutionSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testSynchronousExecute() throws Exception { Ignite ignite = G.ignite(getTestIgniteInstanceName()); @@ -120,4 +125,4 @@ public class GridTaskInstanceExecutionSelfTest extends GridCommonAbstractTest { return super.reduce(results); } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridTaskInstantiationSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskInstantiationSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskInstantiationSelfTest.java index b50bcb6..1e9b2b7 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskInstantiationSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskInstantiationSelfTest.java @@ -32,12 +32,16 @@ import org.apache.ignite.resources.IgniteInstanceResource; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.apache.ignite.testframework.junits.common.GridCommonTest; import org.jetbrains.annotations.Nullable; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * Tests instantiation of various task types (defined as private inner class, without default constructor, non-public * default constructor). */ @GridCommonTest(group = "Kernal Self") +@RunWith(JUnit4.class) public class GridTaskInstantiationSelfTest extends GridCommonAbstractTest { /** * Constructor. @@ -49,6 +53,7 @@ public class GridTaskInstantiationSelfTest extends GridCommonAbstractTest { /** * @throws Exception If an error occurs. */ + @Test public void testTasksInstantiation() throws Exception { grid().compute().execute(PrivateClassTask.class, null); @@ -120,4 +125,4 @@ public class GridTaskInstantiationSelfTest extends GridCommonAbstractTest { // No-op. } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridTaskJobRejectSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskJobRejectSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskJobRejectSelfTest.java index a6678da..e5bc966 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskJobRejectSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskJobRejectSelfTest.java @@ -35,6 +35,9 @@ import org.apache.ignite.lang.IgnitePredicate; import org.apache.ignite.spi.collision.fifoqueue.FifoQueueCollisionSpi; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.jetbrains.annotations.Nullable; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; import static java.util.concurrent.TimeUnit.SECONDS; import static org.apache.ignite.events.EventType.EVTS_JOB_EXECUTION; @@ -47,6 +50,7 @@ import static org.apache.ignite.events.EventType.EVT_TASK_FINISHED; /** * Test that rejected job is not failed over. */ +@RunWith(JUnit4.class) public class GridTaskJobRejectSelfTest extends GridCommonAbstractTest { /** {@inheritDoc} */ @Override protected void beforeTestsStarted() throws Exception { @@ -70,6 +74,7 @@ public class GridTaskJobRejectSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testReject() throws Exception { grid(1).events().localListen(new IgnitePredicate<Event>() { @Override public boolean apply(Event evt) { @@ -156,4 +161,4 @@ public class GridTaskJobRejectSelfTest extends GridCommonAbstractTest { return null; } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridTaskListenerSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskListenerSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskListenerSelfTest.java index 26da6aa..3505c4a 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskListenerSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskListenerSelfTest.java @@ -34,11 +34,15 @@ import org.apache.ignite.lang.IgniteFuture; import org.apache.ignite.lang.IgniteInClosure; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.apache.ignite.testframework.junits.common.GridCommonTest; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * This test checks that GridTaskListener is only called once per task. */ @GridCommonTest(group = "Kernal Self") +@RunWith(JUnit4.class) public class GridTaskListenerSelfTest extends GridCommonAbstractTest { /** */ public GridTaskListenerSelfTest() { @@ -51,6 +55,7 @@ public class GridTaskListenerSelfTest extends GridCommonAbstractTest { * @throws Exception If failed. */ @SuppressWarnings({"BusyWait"}) + @Test public void testGridTaskListener() throws Exception { final AtomicInteger cnt = new AtomicInteger(0); @@ -110,4 +115,4 @@ public class GridTaskListenerSelfTest extends GridCommonAbstractTest { return null; } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridTaskMapAsyncSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskMapAsyncSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskMapAsyncSelfTest.java index 17e2cbd..aa11356 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskMapAsyncSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskMapAsyncSelfTest.java @@ -36,11 +36,15 @@ import org.apache.ignite.spi.discovery.tcp.ipfinder.vm.TcpDiscoveryVmIpFinder; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.apache.ignite.testframework.junits.common.GridCommonTest; import org.jetbrains.annotations.Nullable; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * */ @GridCommonTest(group = "Kernal Self") +@RunWith(JUnit4.class) public class GridTaskMapAsyncSelfTest extends GridCommonAbstractTest { /** * @@ -65,6 +69,7 @@ public class GridTaskMapAsyncSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testTaskMap() throws Exception { Ignite ignite = G.ignite(getTestIgniteInstanceName()); @@ -145,4 +150,4 @@ public class GridTaskMapAsyncSelfTest extends GridCommonAbstractTest { return null; } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridTaskNameAnnotationSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskNameAnnotationSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskNameAnnotationSelfTest.java index b8c54e9..e464371 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskNameAnnotationSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskNameAnnotationSelfTest.java @@ -32,12 +32,16 @@ import org.apache.ignite.internal.util.typedef.F; import org.apache.ignite.resources.TaskSessionResource; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.jetbrains.annotations.Nullable; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; import static org.apache.ignite.compute.ComputeJobResultPolicy.WAIT; /** * Tests for {@link org.apache.ignite.compute.ComputeTaskName} annotation. */ +@RunWith(JUnit4.class) public class GridTaskNameAnnotationSelfTest extends GridCommonAbstractTest { /** Task name. */ private static final String TASK_NAME = "test-task"; @@ -55,6 +59,7 @@ public class GridTaskNameAnnotationSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testClass() throws Exception { assert grid().compute().execute(TestTask.class, null).equals(TASK_NAME); } @@ -62,6 +67,7 @@ public class GridTaskNameAnnotationSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testClassPeerDeployAware() throws Exception { assert grid().compute().execute(PeerDeployAwareTestTask.class, null).equals(PEER_DEPLOY_AWARE_TASK_NAME); } @@ -69,6 +75,7 @@ public class GridTaskNameAnnotationSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testInstance() throws Exception { assert grid().compute().execute(new TestTask(), null).equals(TASK_NAME); } @@ -76,6 +83,7 @@ public class GridTaskNameAnnotationSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testInstancePeerDeployAware() throws Exception { assert grid().compute().execute(new PeerDeployAwareTestTask(), null). equals(PEER_DEPLOY_AWARE_TASK_NAME); @@ -125,4 +133,4 @@ public class GridTaskNameAnnotationSelfTest extends GridCommonAbstractTest { return getClass().getClassLoader(); } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridTaskResultCacheSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskResultCacheSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskResultCacheSelfTest.java index c6bb43f..cc5b772 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskResultCacheSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskResultCacheSelfTest.java @@ -31,11 +31,15 @@ import org.apache.ignite.compute.ComputeTaskSplitAdapter; import org.apache.ignite.internal.util.typedef.G; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.apache.ignite.testframework.junits.common.GridCommonTest; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * */ @GridCommonTest(group = "Kernal Self") +@RunWith(JUnit4.class) public class GridTaskResultCacheSelfTest extends GridCommonAbstractTest { /** * @@ -47,6 +51,7 @@ public class GridTaskResultCacheSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testNoCacheResultAnnotationUsage() throws Exception { Ignite ignite = G.ignite(getTestIgniteInstanceName()); @@ -57,6 +62,7 @@ public class GridTaskResultCacheSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testNoCacheResultMethodUsage() throws Exception { Ignite ignite = G.ignite(getTestIgniteInstanceName()); @@ -67,6 +73,7 @@ public class GridTaskResultCacheSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testCacheResults() throws Exception { Ignite ignite = G.ignite(getTestIgniteInstanceName()); @@ -150,4 +157,4 @@ public class GridTaskResultCacheSelfTest extends GridCommonAbstractTest { return jobs; } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridTaskTimeoutSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskTimeoutSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskTimeoutSelfTest.java index c8b5491..760d0a8 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskTimeoutSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskTimeoutSelfTest.java @@ -41,6 +41,9 @@ import org.apache.ignite.lang.IgniteUuid; import org.apache.ignite.resources.LoggerResource; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; import org.apache.ignite.testframework.junits.common.GridCommonTest; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; import static org.apache.ignite.events.EventType.EVT_TASK_TIMEDOUT; @@ -48,6 +51,7 @@ import static org.apache.ignite.events.EventType.EVT_TASK_TIMEDOUT; * */ @GridCommonTest(group = "Kernal Self") +@RunWith(JUnit4.class) public class GridTaskTimeoutSelfTest extends GridCommonAbstractTest { /** Number of jobs each task spawns. */ private static final int SPLIT_COUNT = 1; @@ -84,6 +88,7 @@ public class GridTaskTimeoutSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testSynchronousTimeout() throws Exception { Ignite ignite = G.ignite(getTestIgniteInstanceName()); @@ -109,6 +114,7 @@ public class GridTaskTimeoutSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testAsynchronousTimeout() throws Exception { Ignite ignite = G.ignite(getTestIgniteInstanceName()); @@ -126,6 +132,7 @@ public class GridTaskTimeoutSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testSynchronousTimeoutMultithreaded() throws Exception { final Ignite ignite = G.ignite(getTestIgniteInstanceName()); @@ -231,4 +238,4 @@ public class GridTaskTimeoutSelfTest extends GridCommonAbstractTest { return null; } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridTopicExternalizableSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridTopicExternalizableSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridTopicExternalizableSelfTest.java index 9ee7402..303f280 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridTopicExternalizableSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridTopicExternalizableSelfTest.java @@ -23,10 +23,14 @@ import org.apache.ignite.GridTestIoUtils; import org.apache.ignite.IgniteExternalizableAbstractTest; import org.apache.ignite.lang.IgniteUuid; import org.apache.ignite.marshaller.Marshaller; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * Grid topic externalization test. */ +@RunWith(JUnit4.class) public class GridTopicExternalizableSelfTest extends IgniteExternalizableAbstractTest { /** */ private static final IgniteUuid A_GRID_UUID = IgniteUuid.randomUuid(); @@ -46,6 +50,7 @@ public class GridTopicExternalizableSelfTest extends IgniteExternalizableAbstrac /** * @throws Exception If failed. */ + @Test public void testSerializationTopicCreatedByGridUuid() throws Exception { for (Marshaller marsh : getMarshallers()) { info("Test GridTopic externalization [marshaller=" + marsh + ']'); @@ -61,6 +66,7 @@ public class GridTopicExternalizableSelfTest extends IgniteExternalizableAbstrac /** * @throws Exception If failed. */ + @Test public void testSerializationTopicCreatedByGridUuidAndUUID() throws Exception { for (Marshaller marsh : getMarshallers()) { info("Test GridTopic externalization [marshaller=" + marsh + ']'); @@ -76,6 +82,7 @@ public class GridTopicExternalizableSelfTest extends IgniteExternalizableAbstrac /** * @throws Exception If failed. */ + @Test public void testSerializationTopicCreatedByGridUuidAndLong() throws Exception { for (Marshaller marsh : getMarshallers()) { info("Test GridTopic externalization [marshaller=" + marsh + ']'); @@ -91,6 +98,7 @@ public class GridTopicExternalizableSelfTest extends IgniteExternalizableAbstrac /** * @throws Exception If failed. */ + @Test public void testSerializationTopicCreatedByStringAndUUIDAndLong() throws Exception { for (Marshaller marsh : getMarshallers()) { info("Test GridTopic externalization [marshaller=" + marsh + ']'); @@ -106,6 +114,7 @@ public class GridTopicExternalizableSelfTest extends IgniteExternalizableAbstrac /** * @throws Exception If failed. */ + @Test public void testSerializationTopicCreatedByString() throws Exception { for (Marshaller marsh : getMarshallers()) { info("Test GridTopic externalization [marshaller=" + marsh + ']'); @@ -121,6 +130,7 @@ public class GridTopicExternalizableSelfTest extends IgniteExternalizableAbstrac /** * @throws Exception If failed. */ + @Test public void testSerializationTopicCreatedByStringAndIntAndLong() throws Exception { for (Marshaller marsh : getMarshallers()) { info("Test GridTopic externalization [marshaller=" + marsh + ']'); @@ -136,6 +146,7 @@ public class GridTopicExternalizableSelfTest extends IgniteExternalizableAbstrac /** * @throws Exception If failed. */ + @Test public void testSerializationTopicCreatedByStrinAndLong() throws Exception { for (Marshaller marsh : getMarshallers()) { info("Test GridTopic externalization [marshaller=" + marsh + ']'); @@ -151,6 +162,7 @@ public class GridTopicExternalizableSelfTest extends IgniteExternalizableAbstrac /** * @throws Exception If failed. */ + @Test public void testSerializationTopicCreatedByStringAndUUIDAndIntAndLong() throws Exception { for (Marshaller marsh : getMarshallers()) { info("Test GridTopic externalization [marshaller=" + marsh + ']'); @@ -162,4 +174,4 @@ public class GridTopicExternalizableSelfTest extends IgniteExternalizableAbstrac } } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/GridVersionSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridVersionSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridVersionSelfTest.java index 4751a0c..396414c 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridVersionSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridVersionSelfTest.java @@ -21,16 +21,21 @@ import org.apache.ignite.internal.util.lang.GridAbsPredicate; import org.apache.ignite.lang.IgniteProductVersion; import org.apache.ignite.testframework.GridTestUtils; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; import static org.apache.ignite.IgniteSystemProperties.IGNITE_UPDATE_NOTIFIER; /** * Tests version methods. */ +@RunWith(JUnit4.class) public class GridVersionSelfTest extends GridCommonAbstractTest { /** * @throws Exception If failed. */ + @Test public void testVersions() throws Exception { String propVal = System.getProperty(IGNITE_UPDATE_NOTIFIER); @@ -63,4 +68,4 @@ public class GridVersionSelfTest extends GridCommonAbstractTest { System.clearProperty(IGNITE_UPDATE_NOTIFIER); } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientConnectAfterCommunicationFailureTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientConnectAfterCommunicationFailureTest.java b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientConnectAfterCommunicationFailureTest.java index 301d5f2..4ae4c56 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientConnectAfterCommunicationFailureTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientConnectAfterCommunicationFailureTest.java @@ -26,10 +26,14 @@ import org.apache.ignite.configuration.IgniteConfiguration; import org.apache.ignite.internal.util.nio.GridCommunicationClient; import org.apache.ignite.internal.util.typedef.internal.U; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * Tests client to be able restore connection to cluster on subsequent attempts after communication problems. */ +@RunWith(JUnit4.class) public class IgniteClientConnectAfterCommunicationFailureTest extends GridCommonAbstractTest { /** {@inheritDoc} */ @@ -54,6 +58,7 @@ public class IgniteClientConnectAfterCommunicationFailureTest extends GridCommon /** * @throws Exception If failed. */ + @Test public void testClientReconnects() throws Exception { Ignite srv1 = startGrid("server1"); Ignite srv2 = startGrid("server2"); @@ -66,6 +71,7 @@ public class IgniteClientConnectAfterCommunicationFailureTest extends GridCommon /** * @throws Exception If failed. */ + @Test public void testClientThreadsSuspended() throws Exception { Ignite srv1 = startGrid("server1"); Ignite srv2 = startGrid("server2"); http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectApiExceptionTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectApiExceptionTest.java b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectApiExceptionTest.java index 8f68a1f..e964ebb 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectApiExceptionTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectApiExceptionTest.java @@ -54,6 +54,9 @@ import org.apache.ignite.lang.IgnitePredicate; import org.apache.ignite.resources.IgniteInstanceResource; import org.apache.ignite.spi.discovery.DiscoverySpi; import org.apache.ignite.testframework.GridTestUtils; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; import static java.util.concurrent.TimeUnit.SECONDS; import static org.apache.ignite.events.EventType.EVT_CLIENT_NODE_DISCONNECTED; @@ -62,6 +65,7 @@ import static org.apache.ignite.events.EventType.EVT_CLIENT_NODE_RECONNECTED; /** * */ +@RunWith(JUnit4.class) public class IgniteClientReconnectApiExceptionTest extends IgniteClientReconnectAbstractTest { /** Cache key for test put and invoke operation after reconnect */ @@ -84,6 +88,7 @@ public class IgniteClientReconnectApiExceptionTest extends IgniteClientReconnect /** * @throws Exception If failed. */ + @Test public void testErrorOnDisconnect() throws Exception { // Check cache operations. cacheOperationsTest(); http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectAtomicsTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectAtomicsTest.java b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectAtomicsTest.java index d1e3ade..e786c31 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectAtomicsTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectAtomicsTest.java @@ -33,10 +33,14 @@ import org.apache.ignite.IgniteSemaphore; import org.apache.ignite.internal.processors.cache.distributed.near.GridNearLockResponse; import org.apache.ignite.internal.processors.cache.distributed.near.GridNearTxPrepareResponse; import org.apache.ignite.testframework.GridTestUtils; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * */ +@RunWith(JUnit4.class) public class IgniteClientReconnectAtomicsTest extends IgniteClientReconnectAbstractTest { /** {@inheritDoc} */ @Override protected int serverCount() { @@ -51,6 +55,7 @@ public class IgniteClientReconnectAtomicsTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testAtomicsReconnectClusterRestart() throws Exception { Ignite client = grid(serverCount()); @@ -106,6 +111,7 @@ public class IgniteClientReconnectAtomicsTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testAtomicSeqReconnect() throws Exception { Ignite client = grid(serverCount()); @@ -139,6 +145,7 @@ public class IgniteClientReconnectAtomicsTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testAtomicSeqReconnectRemoved() throws Exception { Ignite client = grid(serverCount()); @@ -187,6 +194,7 @@ public class IgniteClientReconnectAtomicsTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testAtomicSeqReconnectInProgress() throws Exception { Ignite client = grid(serverCount()); @@ -248,6 +256,7 @@ public class IgniteClientReconnectAtomicsTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testAtomicReferenceReconnect() throws Exception { Ignite client = grid(serverCount()); @@ -289,6 +298,7 @@ public class IgniteClientReconnectAtomicsTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testAtomicReferenceReconnectRemoved() throws Exception { Ignite client = grid(serverCount()); @@ -342,6 +352,7 @@ public class IgniteClientReconnectAtomicsTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testAtomicReferenceReconnectInProgress() throws Exception { Ignite client = grid(serverCount()); @@ -409,6 +420,7 @@ public class IgniteClientReconnectAtomicsTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testAtomicStampedReconnect() throws Exception { Ignite client = grid(serverCount()); @@ -450,6 +462,7 @@ public class IgniteClientReconnectAtomicsTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testAtomicStampedReconnectRemoved() throws Exception { Ignite client = grid(serverCount()); @@ -501,6 +514,7 @@ public class IgniteClientReconnectAtomicsTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testAtomicStampedReconnectInProgress() throws Exception { Ignite client = grid(serverCount()); @@ -569,6 +583,7 @@ public class IgniteClientReconnectAtomicsTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testAtomicLongReconnect() throws Exception { Ignite client = grid(serverCount()); @@ -600,6 +615,7 @@ public class IgniteClientReconnectAtomicsTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testAtomicLongReconnectRemoved() throws Exception { Ignite client = grid(serverCount()); @@ -641,6 +657,7 @@ public class IgniteClientReconnectAtomicsTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testAtomicLongReconnectInProgress() throws Exception { Ignite client = grid(serverCount()); @@ -696,6 +713,7 @@ public class IgniteClientReconnectAtomicsTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testLatchReconnect() throws Exception { Ignite client = grid(serverCount()); @@ -737,6 +755,7 @@ public class IgniteClientReconnectAtomicsTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testSemaphoreReconnect() throws Exception { Ignite client = grid(serverCount()); @@ -778,6 +797,7 @@ public class IgniteClientReconnectAtomicsTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testReentrantLockReconnect() throws Exception { testReentrantLockReconnect(false); http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectBinaryContexTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectBinaryContexTest.java b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectBinaryContexTest.java index 1486476..f7740fa 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectBinaryContexTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectBinaryContexTest.java @@ -25,10 +25,14 @@ import org.apache.ignite.IgniteCache; import org.apache.ignite.cache.CacheMode; import org.apache.ignite.configuration.CacheConfiguration; import org.apache.ignite.configuration.IgniteConfiguration; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * */ +@RunWith(JUnit4.class) public class IgniteClientReconnectBinaryContexTest extends IgniteClientReconnectAbstractTest { /** {@inheritDoc} */ @Override protected int serverCount() { @@ -52,6 +56,7 @@ public class IgniteClientReconnectBinaryContexTest extends IgniteClientReconnect /** * @throws Exception If failed. */ + @Test public void testReconnectCleaningUsersMetadata() throws Exception { Ignite client = grid(serverCount()); http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectCacheTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectCacheTest.java b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectCacheTest.java index bc498da..fb35307 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectCacheTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectCacheTest.java @@ -74,6 +74,9 @@ import org.apache.ignite.transactions.Transaction; import org.apache.ignite.transactions.TransactionConcurrency; import org.apache.ignite.transactions.TransactionIsolation; import org.apache.ignite.transactions.TransactionRollbackException; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; import static java.util.concurrent.TimeUnit.MILLISECONDS; import static org.apache.ignite.cache.CacheAtomicityMode.ATOMIC; @@ -93,6 +96,7 @@ import static org.junit.Assert.assertNotEquals; /** * */ +@RunWith(JUnit4.class) public class IgniteClientReconnectCacheTest extends IgniteClientReconnectAbstractTest { /** */ private static final int SRV_CNT = 3; @@ -156,6 +160,7 @@ public class IgniteClientReconnectCacheTest extends IgniteClientReconnectAbstrac /** * @throws Exception If failed. */ + @Test public void testReconnect() throws Exception { clientMode = true; @@ -335,6 +340,7 @@ public class IgniteClientReconnectCacheTest extends IgniteClientReconnectAbstrac /** * @throws Exception If failed. */ + @Test public void testReconnectTransactions() throws Exception { clientMode = true; @@ -404,6 +410,7 @@ public class IgniteClientReconnectCacheTest extends IgniteClientReconnectAbstrac /** * @throws Exception If failed. */ + @Test public void testTxStateAfterClientReconnect() throws Exception { clientMode = true; @@ -443,6 +450,7 @@ public class IgniteClientReconnectCacheTest extends IgniteClientReconnectAbstrac /** * @throws Exception If failed. */ + @Test public void testReconnectTransactionInProgress1() throws Exception { clientMode = true; @@ -604,6 +612,7 @@ public class IgniteClientReconnectCacheTest extends IgniteClientReconnectAbstrac /** * @throws Exception If failed. */ + @Test public void testReconnectTransactionInProgress2() throws Exception { clientMode = true; @@ -663,6 +672,7 @@ public class IgniteClientReconnectCacheTest extends IgniteClientReconnectAbstrac /** * @throws Exception If failed. */ + @Test public void testReconnectExchangeInProgress() throws Exception { clientMode = true; @@ -725,6 +735,7 @@ public class IgniteClientReconnectCacheTest extends IgniteClientReconnectAbstrac /** * @throws Exception If failed. */ + @Test public void testReconnectInitialExchangeInProgress() throws Exception { final UUID clientId = UUID.randomUUID(); @@ -813,6 +824,7 @@ public class IgniteClientReconnectCacheTest extends IgniteClientReconnectAbstrac /** * @throws Exception If failed. */ + @Test public void testReconnectOperationInProgress() throws Exception { clientMode = true; @@ -885,6 +897,7 @@ public class IgniteClientReconnectCacheTest extends IgniteClientReconnectAbstrac /** * @throws Exception If failed. */ + @Test public void testReconnectCacheDestroyed() throws Exception { clientMode = true; @@ -922,6 +935,7 @@ public class IgniteClientReconnectCacheTest extends IgniteClientReconnectAbstrac /** * @throws Exception If failed. */ + @Test public void testReconnectCacheDestroyedAndCreated() throws Exception { clientMode = true; @@ -965,6 +979,7 @@ public class IgniteClientReconnectCacheTest extends IgniteClientReconnectAbstrac /** * @throws Exception If failed. */ + @Test public void testReconnectMarshallerCache() throws Exception { clientMode = true; @@ -1007,6 +1022,7 @@ public class IgniteClientReconnectCacheTest extends IgniteClientReconnectAbstrac /** * @throws Exception If failed. */ + @Test public void testReconnectClusterRestart() throws Exception { clientMode = true; @@ -1071,6 +1087,7 @@ public class IgniteClientReconnectCacheTest extends IgniteClientReconnectAbstrac /** * @throws Exception If failed. */ + @Test public void testReconnectClusterRestartMultinode() throws Exception { clientMode = true; @@ -1134,6 +1151,7 @@ public class IgniteClientReconnectCacheTest extends IgniteClientReconnectAbstrac /** * @throws Exception If failed. */ + @Test public void testReconnectMultinode() throws Exception { reconnectMultinode(false); } @@ -1141,6 +1159,7 @@ public class IgniteClientReconnectCacheTest extends IgniteClientReconnectAbstrac /** * @throws Exception If failed. */ + @Test public void testReconnectMultinodeLongHistory() throws Exception { reconnectMultinode(true); } @@ -1256,6 +1275,7 @@ public class IgniteClientReconnectCacheTest extends IgniteClientReconnectAbstrac /** * @throws Exception If failed. */ + @Test public void testReconnectDestroyCache() throws Exception { clientMode = true; http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectCollectionsTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectCollectionsTest.java b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectCollectionsTest.java index 5be59b0..5ca64bc 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectCollectionsTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectCollectionsTest.java @@ -29,6 +29,9 @@ import org.apache.ignite.configuration.CollectionConfiguration; import org.apache.ignite.internal.processors.cache.distributed.dht.atomic.GridNearAtomicUpdateResponse; import org.apache.ignite.internal.processors.cache.distributed.near.GridNearTxPrepareResponse; import org.apache.ignite.testframework.GridTestUtils; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; import static org.apache.ignite.cache.CacheAtomicityMode.ATOMIC; import static org.apache.ignite.cache.CacheAtomicityMode.TRANSACTIONAL; @@ -37,6 +40,7 @@ import static org.apache.ignite.cache.CacheMode.PARTITIONED; /** * */ +@RunWith(JUnit4.class) public class IgniteClientReconnectCollectionsTest extends IgniteClientReconnectAbstractTest { /** */ private static final CollectionConfiguration TX_CFGS = new CollectionConfiguration(); @@ -65,6 +69,7 @@ public class IgniteClientReconnectCollectionsTest extends IgniteClientReconnectA /** * @throws Exception If failed. */ + @Test public void testCollectionsReconnectClusterRestart() throws Exception { Ignite client = grid(serverCount()); @@ -113,6 +118,7 @@ public class IgniteClientReconnectCollectionsTest extends IgniteClientReconnectA /** * @throws Exception If failed. */ + @Test public void testQueueReconnect() throws Exception { queueReconnect(TX_CFGS); @@ -122,6 +128,7 @@ public class IgniteClientReconnectCollectionsTest extends IgniteClientReconnectA /** * @throws Exception If failed. */ + @Test public void testQueueReconnectRemoved() throws Exception { queueReconnectRemoved(TX_CFGS); @@ -131,6 +138,7 @@ public class IgniteClientReconnectCollectionsTest extends IgniteClientReconnectA /** * @throws Exception If failed. */ + @Test public void testQueueReconnectInProgress() throws Exception { queueReconnectInProgress(TX_CFGS); @@ -140,6 +148,7 @@ public class IgniteClientReconnectCollectionsTest extends IgniteClientReconnectA /** * @throws Exception If failed. */ + @Test public void testSetReconnect() throws Exception { setReconnect(TX_CFGS); @@ -149,6 +158,7 @@ public class IgniteClientReconnectCollectionsTest extends IgniteClientReconnectA /** * @throws Exception If failed. */ + @Test public void testSetReconnectRemoved() throws Exception { setReconnectRemove(TX_CFGS); @@ -158,6 +168,7 @@ public class IgniteClientReconnectCollectionsTest extends IgniteClientReconnectA /** * @throws Exception If failed. */ + @Test public void testSetReconnectInProgress() throws Exception { setReconnectInProgress(TX_CFGS); @@ -167,6 +178,7 @@ public class IgniteClientReconnectCollectionsTest extends IgniteClientReconnectA /** * @throws Exception If failed. */ + @Test public void testServerReconnect() throws Exception { serverNodeReconnect(TX_CFGS); http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectComputeTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectComputeTest.java b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectComputeTest.java index 57d3188..2dcb580 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectComputeTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectComputeTest.java @@ -26,10 +26,14 @@ import org.apache.ignite.IgniteClientDisconnectedException; import org.apache.ignite.lang.IgniteCallable; import org.apache.ignite.lang.IgniteClosure; import org.apache.ignite.testframework.GridTestUtils; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * */ +@RunWith(JUnit4.class) public class IgniteClientReconnectComputeTest extends IgniteClientReconnectAbstractTest { /** {@inheritDoc} */ @Override protected int serverCount() { @@ -44,6 +48,7 @@ public class IgniteClientReconnectComputeTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testReconnectAffinityCallInProgress() throws Exception { final Ignite client = grid(serverCount()); @@ -98,6 +103,7 @@ public class IgniteClientReconnectComputeTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testReconnectBroadcastInProgress() throws Exception { final Ignite client = grid(serverCount()); @@ -147,6 +153,7 @@ public class IgniteClientReconnectComputeTest extends IgniteClientReconnectAbstr /** * @throws Exception If failed. */ + @Test public void testReconnectApplyInProgress() throws Exception { final Ignite client = grid(serverCount()); @@ -192,4 +199,4 @@ public class IgniteClientReconnectComputeTest extends IgniteClientReconnectAbstr assertTrue((Boolean)fut.get(2, TimeUnit.SECONDS)); } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectContinuousProcessorTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectContinuousProcessorTest.java b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectContinuousProcessorTest.java index d68fc1c..3e80a3f 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectContinuousProcessorTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectContinuousProcessorTest.java @@ -33,6 +33,9 @@ import org.apache.ignite.internal.util.typedef.P2; import org.apache.ignite.lang.IgnitePredicate; import org.apache.ignite.lang.IgniteRunnable; import org.apache.ignite.resources.IgniteInstanceResource; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; import static java.util.concurrent.TimeUnit.MILLISECONDS; import static org.apache.ignite.events.EventType.EVT_CLIENT_NODE_RECONNECTED; @@ -40,6 +43,7 @@ import static org.apache.ignite.events.EventType.EVT_CLIENT_NODE_RECONNECTED; /** * */ +@RunWith(JUnit4.class) public class IgniteClientReconnectContinuousProcessorTest extends IgniteClientReconnectAbstractTest { /** */ private static volatile CountDownLatch latch; @@ -57,6 +61,7 @@ public class IgniteClientReconnectContinuousProcessorTest extends IgniteClientRe /** * @throws Exception If failed. */ + @Test public void testEventListenerReconnect() throws Exception { Ignite client = grid(serverCount()); @@ -114,6 +119,7 @@ public class IgniteClientReconnectContinuousProcessorTest extends IgniteClientRe /** * @throws Exception If failed. */ + @Test public void testMessageListenerReconnectAndStopFromServer() throws Exception { testMessageListenerReconnect(false); } @@ -121,6 +127,7 @@ public class IgniteClientReconnectContinuousProcessorTest extends IgniteClientRe /** * @throws Exception If failed. */ + @Test public void testMessageListenerReconnectAndStopFromClient() throws Exception { testMessageListenerReconnect(true); } @@ -212,6 +219,7 @@ public class IgniteClientReconnectContinuousProcessorTest extends IgniteClientRe /** * @throws Exception If failed. */ + @Test public void testCacheContinuousQueryReconnect() throws Exception { Ignite client = grid(serverCount()); @@ -249,6 +257,7 @@ public class IgniteClientReconnectContinuousProcessorTest extends IgniteClientRe /** * @throws Exception If failed. */ + @Test public void testCacheContinuousQueryReconnectNewServer() throws Exception { Ignite client = grid(serverCount()); @@ -457,4 +466,4 @@ public class IgniteClientReconnectContinuousProcessorTest extends IgniteClientRe ignite.log().info("Job run."); } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectDelayedSpiTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectDelayedSpiTest.java b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectDelayedSpiTest.java index a4a0912..8c70cec 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectDelayedSpiTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectDelayedSpiTest.java @@ -30,11 +30,15 @@ import org.apache.ignite.internal.util.typedef.F; import org.apache.ignite.lang.IgniteBiPredicate; import org.apache.ignite.plugin.extensions.communication.Message; import org.apache.ignite.testframework.GridTestUtils; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * Test cases for emulation of delayed messages sending with {@link TestRecordingCommunicationSpi} for blocking and * resending messages at the moment we need it. */ +@RunWith(JUnit4.class) public class IgniteClientReconnectDelayedSpiTest extends IgniteClientReconnectAbstractTest { /** {@inheritDoc} */ @Override protected IgniteConfiguration getConfiguration(String igniteInstanceName) throws Exception { @@ -59,6 +63,7 @@ public class IgniteClientReconnectDelayedSpiTest extends IgniteClientReconnectAb * * @throws Exception If failed. */ + @Test public void testReconnectCacheDestroyedDelayedAffinityChange() throws Exception { Ignite ignite = ignite(1); http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectDiscoveryStateTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectDiscoveryStateTest.java b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectDiscoveryStateTest.java index 6e77742..d002667 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectDiscoveryStateTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectDiscoveryStateTest.java @@ -28,6 +28,9 @@ import org.apache.ignite.events.Event; import org.apache.ignite.lang.IgniteFuture; import org.apache.ignite.lang.IgnitePredicate; import org.apache.ignite.spi.discovery.DiscoverySpi; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; import static org.apache.ignite.events.EventType.EVT_CLIENT_NODE_DISCONNECTED; import static org.apache.ignite.events.EventType.EVT_CLIENT_NODE_RECONNECTED; @@ -35,6 +38,7 @@ import static org.apache.ignite.events.EventType.EVT_CLIENT_NODE_RECONNECTED; /** * */ +@RunWith(JUnit4.class) public class IgniteClientReconnectDiscoveryStateTest extends IgniteClientReconnectAbstractTest { /** {@inheritDoc} */ @Override protected int serverCount() { @@ -49,6 +53,7 @@ public class IgniteClientReconnectDiscoveryStateTest extends IgniteClientReconne /** * @throws Exception If failed. */ + @Test public void testReconnect() throws Exception { final Ignite client = ignite(serverCount()); @@ -132,4 +137,4 @@ public class IgniteClientReconnectDiscoveryStateTest extends IgniteClientReconne assertEquals(10, cluster.nodeLocalMap().get("locMapKey")); } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectFailoverTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectFailoverTest.java b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectFailoverTest.java index 57c2e93..dd652dd 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectFailoverTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectFailoverTest.java @@ -34,6 +34,9 @@ import org.apache.ignite.configuration.IgniteConfiguration; import org.apache.ignite.lang.IgniteCallable; import org.apache.ignite.transactions.Transaction; import org.apache.ignite.transactions.TransactionConcurrency; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; import static org.apache.ignite.cache.CacheAtomicityMode.ATOMIC; import static org.apache.ignite.cache.CacheAtomicityMode.TRANSACTIONAL; @@ -43,6 +46,7 @@ import static org.apache.ignite.transactions.TransactionIsolation.REPEATABLE_REA /** * */ +@RunWith(JUnit4.class) public class IgniteClientReconnectFailoverTest extends IgniteClientReconnectFailoverAbstractTest { /** */ protected static final String ATOMIC_CACHE = "ATOMIC_CACHE"; @@ -75,6 +79,7 @@ public class IgniteClientReconnectFailoverTest extends IgniteClientReconnectFail /** * @throws Exception If failed. */ + @Test public void testReconnectAtomicCache() throws Exception { final Ignite client = grid(serverCount()); @@ -114,6 +119,7 @@ public class IgniteClientReconnectFailoverTest extends IgniteClientReconnectFail /** * @throws Exception If failed. */ + @Test public void testReconnectTxCache() throws Exception { final Ignite client = grid(serverCount()); @@ -181,6 +187,7 @@ public class IgniteClientReconnectFailoverTest extends IgniteClientReconnectFail /** * @throws Exception If failed. */ + @Test public void testReconnectComputeApi() throws Exception { final Ignite client = grid(serverCount()); @@ -200,6 +207,7 @@ public class IgniteClientReconnectFailoverTest extends IgniteClientReconnectFail /** * @throws Exception If failed. */ + @Test public void testReconnectStreamerApi() throws Exception { final Ignite client = grid(serverCount()); @@ -236,4 +244,4 @@ public class IgniteClientReconnectFailoverTest extends IgniteClientReconnectFail return 1; } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectServicesTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectServicesTest.java b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectServicesTest.java index 1e6dd64..98803e0 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectServicesTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectServicesTest.java @@ -30,10 +30,14 @@ import org.apache.ignite.resources.IgniteInstanceResource; import org.apache.ignite.services.Service; import org.apache.ignite.services.ServiceContext; import org.apache.ignite.testframework.GridTestUtils; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; /** * */ +@RunWith(JUnit4.class) public class IgniteClientReconnectServicesTest extends IgniteClientReconnectAbstractTest { /** {@inheritDoc} */ @Override protected int serverCount() { @@ -48,6 +52,7 @@ public class IgniteClientReconnectServicesTest extends IgniteClientReconnectAbst /** * @throws Exception If failed. */ + @Test public void testReconnect() throws Exception { Ignite client = grid(serverCount()); @@ -83,6 +88,7 @@ public class IgniteClientReconnectServicesTest extends IgniteClientReconnectAbst /** * @throws Exception If failed. */ + @Test public void testServiceRemove() throws Exception { Ignite client = grid(serverCount()); @@ -125,6 +131,7 @@ public class IgniteClientReconnectServicesTest extends IgniteClientReconnectAbst /** * @throws Exception If failed. */ + @Test public void testReconnectInDeploying() throws Exception { Ignite client = grid(serverCount()); @@ -172,6 +179,7 @@ public class IgniteClientReconnectServicesTest extends IgniteClientReconnectAbst /** * @throws Exception If failed. */ + @Test public void testReconnectInProgress() throws Exception { Ignite client = grid(serverCount()); @@ -262,4 +270,4 @@ public class IgniteClientReconnectServicesTest extends IgniteClientReconnectAbst return ignite.cluster().topologyVersion(); } } -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/ignite/blob/f0544d46/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectStopTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectStopTest.java b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectStopTest.java index b5c3ee8..f83b5d8 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectStopTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/IgniteClientReconnectStopTest.java @@ -27,6 +27,9 @@ import org.apache.ignite.internal.managers.discovery.IgniteDiscoverySpi; import org.apache.ignite.lang.IgniteFuture; import org.apache.ignite.lang.IgnitePredicate; import org.apache.ignite.spi.discovery.DiscoverySpi; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; import static org.apache.ignite.events.EventType.EVT_CLIENT_NODE_DISCONNECTED; import static org.apache.ignite.events.EventType.EVT_CLIENT_NODE_RECONNECTED; @@ -34,6 +37,7 @@ import static org.apache.ignite.events.EventType.EVT_CLIENT_NODE_RECONNECTED; /** * */ +@RunWith(JUnit4.class) public class IgniteClientReconnectStopTest extends IgniteClientReconnectAbstractTest { /** {@inheritDoc} */ @Override protected int serverCount() { @@ -43,6 +47,7 @@ public class IgniteClientReconnectStopTest extends IgniteClientReconnectAbstract /** * @throws Exception If failed. */ + @Test public void testStopWhenDisconnected() throws Exception { clientMode = true; @@ -112,4 +117,4 @@ public class IgniteClientReconnectStopTest extends IgniteClientReconnectAbstract log.info("Expected reconnect exception: " + e); } } -} \ No newline at end of file +}