Skip to content

Commit 2a7941b

Browse files
committed
Don't use jimfs when testing DocMigratorTest
`copyToRecursively` does not work correctly when copying from Windows paths to jimfs.
1 parent b00a035 commit 2a7941b

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

pkl-doc/src/test/kotlin/org/pkl/doc/DocMigratorTest.kt

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,7 @@
1717

1818
package org.pkl.doc
1919

20-
import com.google.common.jimfs.Configuration
21-
import com.google.common.jimfs.Jimfs
2220
import java.io.OutputStream
23-
import java.nio.file.FileSystem
2421
import java.nio.file.Files
2522
import java.nio.file.Path
2623
import kotlin.io.path.*
@@ -38,8 +35,6 @@ import org.pkl.core.util.IoUtils
3835

3936
class DocMigratorTest {
4037
companion object {
41-
private val tempFileSystem: FileSystem by lazy { Jimfs.newFileSystem(Configuration.unix()) }
42-
4338
private val projectDir = FileTestUtils.rootProjectDir.resolve("pkl-doc")
4439

4540
private val inputDir: Path by lazy {
@@ -52,9 +47,7 @@ class DocMigratorTest {
5247
projectDir.resolve("src/test/files/DocMigratorTest/output/").also { it.createDirectories() }
5348
}
5449

55-
private val actualOutputDir: Path by lazy {
56-
tempFileSystem.getPath("/work/output").createDirectories()
57-
}
50+
private val actualOutputDir: Path by lazy { Files.createTempDirectory("docMigratorTest") }
5851

5952
private val actualOutputFiles: List<Path> by lazy { actualOutputDir.listFilesRecursively() }
6053

0 commit comments

Comments
 (0)