Repository: incubator-geode
Updated Branches:
  refs/heads/develop 1c8688243 -> 7d15174d5


GEODE-11 - Fixing failure in FileSystemJUnitTest

This test was listing files in a directory and making assertions about
the order in which they would return. Sorting the list of files before
making assertions because the order is not guaranteed.


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

Branch: refs/heads/develop
Commit: 7d15174d5cc4ddd829bed704416ded36b1f32c3c
Parents: 1c86882
Author: Dan Smith <[email protected]>
Authored: Wed Jun 1 13:33:54 2016 -0700
Committer: Dan Smith <[email protected]>
Committed: Wed Jun 1 13:34:28 2016 -0700

----------------------------------------------------------------------
 .../cache/lucene/internal/filesystem/FileSystemJUnitTest.java    | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/7d15174d/geode-lucene/src/test/java/com/gemstone/gemfire/cache/lucene/internal/filesystem/FileSystemJUnitTest.java
----------------------------------------------------------------------
diff --git 
a/geode-lucene/src/test/java/com/gemstone/gemfire/cache/lucene/internal/filesystem/FileSystemJUnitTest.java
 
b/geode-lucene/src/test/java/com/gemstone/gemfire/cache/lucene/internal/filesystem/FileSystemJUnitTest.java
index a72f7d1..32d8590 100644
--- 
a/geode-lucene/src/test/java/com/gemstone/gemfire/cache/lucene/internal/filesystem/FileSystemJUnitTest.java
+++ 
b/geode-lucene/src/test/java/com/gemstone/gemfire/cache/lucene/internal/filesystem/FileSystemJUnitTest.java
@@ -490,7 +490,9 @@ public class FileSystemJUnitTest {
 
     java.io.File parentDir = dirRule.get();
     system.export(dirRule.get());
-    assertArrayEquals(new String[] {"testFile1", "testFile2"}, 
parentDir.list());
+    String[] foundFiles = parentDir.list();
+    Arrays.sort(foundFiles);
+    assertArrayEquals(new String[] {"testFile1", "testFile2"}, foundFiles);
 
     assertExportedFileContents(file1Data, new java.io.File(parentDir, 
"testFile1"));
     assertExportedFileContents(file2Data, new java.io.File(parentDir, 
"testFile2"));

Reply via email to