geode-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hiteshkhame...@apache.org
Subject [63/65] [abbrv] incubator-geode git commit: GEODE-37 fixed unit test
Date Thu, 15 Sep 2016 02:00:24 GMT
GEODE-37 fixed unit test


Project: http://git-wip-us.apache.org/repos/asf/incubator-geode/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-geode/commit/7c4250ea
Tree: http://git-wip-us.apache.org/repos/asf/incubator-geode/tree/7c4250ea
Diff: http://git-wip-us.apache.org/repos/asf/incubator-geode/diff/7c4250ea

Branch: refs/heads/develop
Commit: 7c4250ea2f7f315d22dd1a3bcca4b1c3729fef49
Parents: 0638484
Author: Hitesh Khamesra <hkhamesra@pivotal.io>
Authored: Tue Sep 13 16:35:42 2016 -0700
Committer: Hitesh Khamesra <hkhamesra@pivotal.io>
Committed: Tue Sep 13 16:35:42 2016 -0700

----------------------------------------------------------------------
 .../java/org/apache/geode/internal/PdxRenameDUnitTest.java   | 8 ++++----
 .../java/org/apache/geode/internal/PdxRenameJUnitTest.java   | 8 ++++----
 .../geode/internal/cache/EvictionObjectSizerDUnitTest.java   | 8 ++++----
 .../internal/cli/commands/DiskStoreCommandsDUnitTest.java    | 6 +++---
 .../java/org/apache/geode/pdx/AutoSerializableJUnitTest.java | 2 +-
 5 files changed, 16 insertions(+), 16 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/7c4250ea/geode-core/src/test/java/org/apache/geode/internal/PdxRenameDUnitTest.java
----------------------------------------------------------------------
diff --git a/geode-core/src/test/java/org/apache/geode/internal/PdxRenameDUnitTest.java b/geode-core/src/test/java/org/apache/geode/internal/PdxRenameDUnitTest.java
index 7759e9e..7b3173c 100644
--- a/geode-core/src/test/java/org/apache/geode/internal/PdxRenameDUnitTest.java
+++ b/geode-core/src/test/java/org/apache/geode/internal/PdxRenameDUnitTest.java
@@ -122,16 +122,16 @@ public class PdxRenameDUnitTest  extends JUnit4CacheTestCase{
     
     vm1.invoke(new SerializableCallable() {
       public Object call() throws Exception {
-        Collection<Object> renameResults = DiskStoreImpl.pdxRename(DS_NAME, new File[]{f},
"gemstone", "pivotal");
+        Collection<Object> renameResults = DiskStoreImpl.pdxRename(DS_NAME, new File[]{f},
"apache", "pivotal");
         assertEquals(2, renameResults.size());
         
         for(Object o : renameResults) {
           if(o instanceof PdxType) {
             PdxType t = (PdxType)o;
-            assertEquals("com.pivotal.gemfire.internal.PdxRenameDUnitTest$PdxValue", t.getClassName());
+            assertEquals("org.pivotal.geode.internal.PdxRenameDUnitTest$PdxValue", t.getClassName());
           } else {
             EnumInfo ei = (EnumInfo) o;
-            assertEquals("com.pivotal.gemfire.internal.PdxRenameDUnitTest$Day", ei.getClassName());
+            assertEquals("org.pivotal.geode.internal.PdxRenameDUnitTest$Day", ei.getClassName());
           }
         }
         return null;
@@ -166,7 +166,7 @@ public class PdxRenameDUnitTest  extends JUnit4CacheTestCase{
         Region region1 = rf1.create("region1");
         PdxInstance v = (PdxInstance) region1.get("key1");
         assertNotNull(v);
-        assertEquals("com.pivotal.gemfire.internal.PdxRenameDUnitTest$PdxValue", ((PdxInstanceImpl)v).getClassName());
+        assertEquals("org.pivotal.geode.internal.PdxRenameDUnitTest$PdxValue", ((PdxInstanceImpl)v).getClassName());
         cache.close();
         return null;
       }

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/7c4250ea/geode-core/src/test/java/org/apache/geode/internal/PdxRenameJUnitTest.java
----------------------------------------------------------------------
diff --git a/geode-core/src/test/java/org/apache/geode/internal/PdxRenameJUnitTest.java b/geode-core/src/test/java/org/apache/geode/internal/PdxRenameJUnitTest.java
index 87a79d7..642b8aa 100644
--- a/geode-core/src/test/java/org/apache/geode/internal/PdxRenameJUnitTest.java
+++ b/geode-core/src/test/java/org/apache/geode/internal/PdxRenameJUnitTest.java
@@ -91,21 +91,21 @@ public class PdxRenameJUnitTest {
         region1.put("key1", new PdxValue(1));
         cache.close();
 
-        Collection<Object> renameResults = DiskStoreImpl.pdxRename(DS_NAME, new File[]{f},
"gemstone", "pivotal");
+        Collection<Object> renameResults = DiskStoreImpl.pdxRename(DS_NAME, new File[]{f},
"apache", "pivotal");
         assertEquals(2, renameResults.size());
         
         for(Object o : renameResults) {
           if(o instanceof PdxType) {
             PdxType t = (PdxType)o;
-            assertEquals("com.pivotal.gemfire.internal.PdxRenameJUnitTest$PdxValue", t.getClassName());
+            assertEquals("org.pivotal.geode.internal.PdxRenameJUnitTest$PdxValue", t.getClassName());
           } else {
             EnumInfo ei = (EnumInfo) o;
-            assertEquals("com.pivotal.gemfire.internal.PdxRenameJUnitTest$Day", ei.getClassName());
+            assertEquals("org.pivotal.geode.internal.PdxRenameJUnitTest$Day", ei.getClassName());
           }
         }
         Collection<PdxType> types = DiskStoreImpl.getPdxTypes(DS_NAME, new File[]{f});
         assertEquals(1, types.size());
-        assertEquals("com.pivotal.gemfire.internal.PdxRenameJUnitTest$PdxValue", types.iterator().next().getClassName());
+        assertEquals("org.pivotal.geode.internal.PdxRenameJUnitTest$PdxValue", types.iterator().next().getClassName());
 
       } finally {
         if (!cache.isClosed()) {

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/7c4250ea/geode-core/src/test/java/org/apache/geode/internal/cache/EvictionObjectSizerDUnitTest.java
----------------------------------------------------------------------
diff --git a/geode-core/src/test/java/org/apache/geode/internal/cache/EvictionObjectSizerDUnitTest.java
b/geode-core/src/test/java/org/apache/geode/internal/cache/EvictionObjectSizerDUnitTest.java
index 0e01fd4..c2a9a68 100644
--- a/geode-core/src/test/java/org/apache/geode/internal/cache/EvictionObjectSizerDUnitTest.java
+++ b/geode-core/src/test/java/org/apache/geode/internal/cache/EvictionObjectSizerDUnitTest.java
@@ -173,10 +173,10 @@ public class EvictionObjectSizerDUnitTest extends JUnit4CacheTestCase
{
 
     // Size of overhead= 49
     // Size of Integer key= 0(inlined)
-    // Size of TestObjectSizerImpl= 160 (serialized size)
+    // Size of TestObjectSizerImpl= 160 (serialized size), changed to 156 because package
changed to org.apache.geode
     // Total Size of entry should be= 71
     putCustomizedData(1, new TestObjectSizerImpl());
-    int expected = (0+160+(Sizeable.PER_OBJECT_OVERHEAD*2)+((HeapLRUCapacityController)((PartitionedRegion)region).getEvictionController()).getPerEntryOverhead());
+    int expected = (0+156+(Sizeable.PER_OBJECT_OVERHEAD*2)+((HeapLRUCapacityController)((PartitionedRegion)region).getEvictionController()).getPerEntryOverhead());
     LogWriterUtils.getLogWriter().info("testObjectSizerForHeapLRU_CustomizedSizerObject expected=
" + expected);
     assertEquals(expected, getSizeOfCustomizedData(1));
     assertEquals(expected, ((PartitionedRegion)region).getEvictionController()
@@ -192,10 +192,10 @@ public class EvictionObjectSizerDUnitTest extends JUnit4CacheTestCase
{
 
     // Size of overhead= 49
     // Size of TestNonSizerObject key= 1(customized)
-    // Size of TestObjectSizerImpl= 160 (serialized size)
+    // Size of TestObjectSizerImpl= 160 (serialized size), changed to 156 because package
changed to org.apache.geode
     // Total Size of entry should be= 72
     putCustomizedObjects(new TestNonSizerObject("1"), new TestObjectSizerImpl());
-    int expected = (1+160+(Sizeable.PER_OBJECT_OVERHEAD*2)+((HeapLRUCapacityController)((PartitionedRegion)region).getEvictionController()).getPerEntryOverhead());
+    int expected = (1+156+(Sizeable.PER_OBJECT_OVERHEAD*2)+((HeapLRUCapacityController)((PartitionedRegion)region).getEvictionController()).getPerEntryOverhead());
     LogWriterUtils.getLogWriter().info("testObjectSizerForHeapLRU_CustomizedSizerObjects
expected= " + expected);
     assertEquals(expected, getSizeOfCustomizedObject(new TestNonSizerObject("1")));
     assertEquals(expected, ((PartitionedRegion)region).getEvictionController()

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/7c4250ea/geode-core/src/test/java/org/apache/geode/management/internal/cli/commands/DiskStoreCommandsDUnitTest.java
----------------------------------------------------------------------
diff --git a/geode-core/src/test/java/org/apache/geode/management/internal/cli/commands/DiskStoreCommandsDUnitTest.java
b/geode-core/src/test/java/org/apache/geode/management/internal/cli/commands/DiskStoreCommandsDUnitTest.java
index bb574ca..9926ae6 100644
--- a/geode-core/src/test/java/org/apache/geode/management/internal/cli/commands/DiskStoreCommandsDUnitTest.java
+++ b/geode-core/src/test/java/org/apache/geode/management/internal/cli/commands/DiskStoreCommandsDUnitTest.java
@@ -326,10 +326,10 @@ public class DiskStoreCommandsDUnitTest extends CliCommandTestBase {
     CommandResult cmdResult = executeCommand("describe offline-disk-store --name=" + diskStoreName1
+ " --disk-dirs=" + diskStoreDir.getAbsolutePath() + " --pdx=true");
     String stringResult = commandResultToString(cmdResult);
     assertTrue(stringContainsLine(stringResult, ".*PDX Types.*"));
-    assertTrue(stringContainsLine(stringResult, ".*com\\.gemstone\\.gemfire\\.cache\\.query\\.data\\.PortfolioPdx.*"));
-    assertTrue(stringContainsLine(stringResult, ".*com\\.gemstone\\.gemfire\\.cache\\.query\\.data\\.PositionPdx.*"));
+    assertTrue(stringContainsLine(stringResult, ".*org\\.apache\\.geode\\.cache\\.query\\.data\\.PortfolioPdx.*"));
+    assertTrue(stringContainsLine(stringResult, ".*org\\.apache\\.geode\\.cache\\.query\\.data\\.PositionPdx.*"));
     assertTrue(stringContainsLine(stringResult, ".*PDX Enums.*"));
-    assertTrue(stringContainsLine(stringResult, ".*com\\.gemstone\\.gemfire\\.cache\\.query\\.data\\.PortfolioPdx\\$Day.*"));
+    assertTrue(stringContainsLine(stringResult, ".*org\\.apache\\.geode\\.cache\\.query\\.data\\.PortfolioPdx\\$Day.*"));
   }
 
   @Test

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/7c4250ea/geode-core/src/test/java/org/apache/geode/pdx/AutoSerializableJUnitTest.java
----------------------------------------------------------------------
diff --git a/geode-core/src/test/java/org/apache/geode/pdx/AutoSerializableJUnitTest.java
b/geode-core/src/test/java/org/apache/geode/pdx/AutoSerializableJUnitTest.java
index f97291a..0c222c8 100644
--- a/geode-core/src/test/java/org/apache/geode/pdx/AutoSerializableJUnitTest.java
+++ b/geode-core/src/test/java/org/apache/geode/pdx/AutoSerializableJUnitTest.java
@@ -1219,7 +1219,7 @@ public class AutoSerializableJUnitTest {
     setupSerializer(stdSerializableClasses);
     ChildFirstClassLoader cfcl = 
         new ChildFirstClassLoader(javaClassPathToUrl(), this.getClass().getClassLoader());
-    cfcl.addIncludedClass("com\\.gemstone.*");
+    cfcl.addIncludedClass("org\\.apache.*");
     // Need to exclude DomainObject as that is what the newly created objects
     // get cast to.
     cfcl.addExcludedClass(".*DomainObject");


Mime
View raw message