You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ignite.apache.org by sb...@apache.org on 2015/05/12 13:30:50 UTC
[31/37] incubator-ignite git commit: #ignite-373: Add additional
debug information to removeAll test.
#ignite-373: Add additional debug information to removeAll test.
Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/2828cb8c
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/2828cb8c
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/2828cb8c
Branch: refs/heads/ignite-373
Commit: 2828cb8cf6cdc8d6370ab6a9047819db5d9bff78
Parents: 1ffe115
Author: ivasilinets <iv...@gridgain.com>
Authored: Tue May 12 13:38:53 2015 +0300
Committer: ivasilinets <iv...@gridgain.com>
Committed: Tue May 12 13:38:53 2015 +0300
----------------------------------------------------------------------
.../cache/CacheRemoveAllSelfTest.java | 31 +++++++++++---------
1 file changed, 17 insertions(+), 14 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/2828cb8c/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheRemoveAllSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheRemoveAllSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheRemoveAllSelfTest.java
index a55ee4b..1f2f3f6 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheRemoveAllSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheRemoveAllSelfTest.java
@@ -19,8 +19,8 @@ package org.apache.ignite.internal.processors.cache;
import org.apache.ignite.*;
import org.apache.ignite.cache.*;
+import org.apache.ignite.configuration.*;
import org.apache.ignite.internal.*;
-import org.apache.ignite.internal.util.typedef.internal.*;
import org.apache.ignite.testframework.*;
import java.util.concurrent.*;
@@ -40,6 +40,11 @@ public class CacheRemoveAllSelfTest extends GridCacheAbstractSelfTest {
return 4;
}
+ /** {@inheritDoc} */
+ @Override protected NearCacheConfiguration nearConfiguration() {
+ return null;
+ }
+
/**
* @throws Exception If failed.
*/
@@ -64,18 +69,16 @@ public class CacheRemoveAllSelfTest extends GridCacheAbstractSelfTest {
fut.get();
- for (int i = 0; i < igniteId.get(); ++i)
- assertEquals("Local entries: " + entrySet(grid(i).cache(null).localEntries(CachePeekMode.PRIMARY)) +
- ". All entries:" +
- entrySet(grid(i).cache(null).localEntries()), 0, grid(i).cache(null).localSize());
-
- U.sleep(5000);
-
- for (int i = 0; i < igniteId.get(); ++i)
- assertEquals("2 Local entries: " + entrySet(grid(i).cache(null).localEntries(CachePeekMode.PRIMARY)) +
- ". All entries:" +
- entrySet(grid(i).cache(null).localEntries()), 0, grid(i).cache(null).localSize());
-
- assertEquals(0, cache.size());
+ for (int i = 0; i < igniteId.get(); ++i) {
+ IgniteCache locCache = grid(i).cache(null);
+
+ assertEquals("Local size: " + locCache.localSize() + "\n" +
+ "On heap: " + locCache.localSize(CachePeekMode.ONHEAP) + "\n" +
+ "Off heap: " + locCache.localSize(CachePeekMode.OFFHEAP) + "\n" +
+ "Swap: " + locCache.localSize(CachePeekMode.SWAP) + "\n" +
+ "Primary: " + locCache.localSize(CachePeekMode.PRIMARY) + "\n" +
+ "Backup: " + locCache.localSize(CachePeekMode.BACKUP),
+ 0, locCache.localSize());
+ }
}
}