diff --git a/cache/src/test/kotlin/org/openrs2/cache/DiskStoreTest.kt b/cache/src/test/kotlin/org/openrs2/cache/DiskStoreTest.kt index 212c3209..06bb5708 100644 --- a/cache/src/test/kotlin/org/openrs2/cache/DiskStoreTest.kt +++ b/cache/src/test/kotlin/org/openrs2/cache/DiskStoreTest.kt @@ -734,8 +734,8 @@ object DiskStoreTest { } private fun writeTest(name: String, f: (Store) -> Unit) { - Jimfs.newFileSystem(Configuration.unix()).use { fs -> - val actual = fs.getPath("/cache") + Jimfs.newFileSystem(Configuration.forCurrentPlatform()).use { fs -> + val actual = fs.rootDirectories.first().resolve("cache") DiskStore.create(actual).use { store -> f(store) } @@ -746,8 +746,8 @@ object DiskStoreTest { } private fun overwriteTest(src: String, name: String, f: (Store) -> Unit) { - Jimfs.newFileSystem(Configuration.unix()).use { fs -> - val actual = fs.getPath("/cache") + Jimfs.newFileSystem(Configuration.forCurrentPlatform()).use { fs -> + val actual = fs.rootDirectories.first().resolve("cache") ROOT.resolve(src).recursiveCopy(actual) DiskStore.open(actual).use { store -> diff --git a/cache/src/test/kotlin/org/openrs2/cache/FlatFileStoreTest.kt b/cache/src/test/kotlin/org/openrs2/cache/FlatFileStoreTest.kt index 1a2e5024..f0b83cd7 100644 --- a/cache/src/test/kotlin/org/openrs2/cache/FlatFileStoreTest.kt +++ b/cache/src/test/kotlin/org/openrs2/cache/FlatFileStoreTest.kt @@ -250,8 +250,8 @@ object FlatFileStoreTest { } private fun writeTest(name: String, f: (Store) -> Unit) { - Jimfs.newFileSystem(Configuration.unix()).use { fs -> - val actual = fs.getPath("/cache") + Jimfs.newFileSystem(Configuration.forCurrentPlatform()).use { fs -> + val actual = fs.rootDirectories.first().resolve("cache") FlatFileStore.create(actual).use { store -> f(store) } @@ -262,8 +262,8 @@ object FlatFileStoreTest { } private fun overwriteTest(src: String, name: String, f: (Store) -> Unit) { - Jimfs.newFileSystem(Configuration.unix()).use { fs -> - val actual = fs.getPath("/cache") + Jimfs.newFileSystem(Configuration.forCurrentPlatform()).use { fs -> + val actual = fs.rootDirectories.first().resolve("cache") ROOT.resolve(src).recursiveCopy(actual) FlatFileStore.open(actual).use { store ->