File tree Expand file tree Collapse file tree
core/src/test/java/org/jetbrains/ktfmt Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -12,12 +12,12 @@ import kotlin.io.path.name
1212import kotlin.io.path.nameWithoutExtension
1313import kotlin.io.path.readText
1414import kotlin.io.path.writeText
15- import kotlin.io.resolve
1615import org.junit.jupiter.api.Assertions.assertEquals
1716import org.junit.jupiter.api.DynamicContainer
1817import org.junit.jupiter.api.DynamicNode
1918import org.junit.jupiter.api.DynamicTest
2019import org.junit.jupiter.api.TestFactory
20+ import java.net.URI
2121
2222/* *
2323 * Base class for a group of file-based formatter cases.
@@ -62,7 +62,7 @@ abstract class FormatterTestFactory(
6262 // Without this, neither 'overwrite' nor navigation in IJ will work
6363 val root = run {
6464 val location = javaClass.protectionDomain?.codeSource?.location!!
65- val root = location.toURI().path.substringBefore(" build/classes/kotlin/test" )
65+ val root = URI ( location.toURI().path.substringBefore(" build/classes/kotlin/test" ) )
6666 Path .of(root).resolve(" src/test/resources/cases" )
6767 }
6868 }
You can’t perform that action at this time.
0 commit comments