Use random file names in tests of persisted maps to avoid inference

This commit is contained in:
leventov
2016-11-20 18:31:44 -06:00
parent 3ac1d643ac
commit 90b538ba64
2 changed files with 2 additions and 2 deletions
@@ -36,7 +36,7 @@ public class ExitHookTest {
public void testExitHook() throws IOException, InterruptedException {
if (!OS.isLinux() && !OS.isMacOSX())
return; // This test runs only in Unix-like OSes
File mapFile = folder.newFile("map");
File mapFile = folder.newFile();
System.out.println("map file: " + mapFile.getAbsolutePath());
// Create a process which opens the map, acquires the lock and "hangs" for 30 seconds
Process process = startOtherProcess(mapFile);
@@ -108,7 +108,7 @@ public class MemoryResourcesTest {
VanillaChronicleMap<IntValue, String, ?> map;
if (persisted) {
map = (VanillaChronicleMap<IntValue, String, ?>)
builder.createPersistedTo(folder.newFile("map.dat"));
builder.createPersistedTo(folder.newFile());
} else {
map = (VanillaChronicleMap<IntValue, String, ?>) builder.create();
}