diff --git a/src/swot/Compiler.kt b/src/swot/Compiler.kt index 138eaad632..35dbf91cbf 100644 --- a/src/swot/Compiler.kt +++ b/src/swot/Compiler.kt @@ -15,7 +15,7 @@ fun main(args: Array) { val root = File("lib/domains") root.walkTopDown().forEach { if (it.isFile) { - val parts = it.relativeTo(root).replace('\\', '/').removeSuffix(".txt").split('/').toList() + val parts = it.toRelativeString(root).replace('\\', '/').removeSuffix(".txt").split('/').toList() if (!checkSet(CompilationState.blacklist, parts) && !checkSet(CompilationState.domains, parts)) { CompilationState.domains.add(parts.reversed().joinToString(".")) } diff --git a/test/swot/SwotTest.kt b/test/swot/SwotTest.kt index 563e2ee638..8585575832 100644 --- a/test/swot/SwotTest.kt +++ b/test/swot/SwotTest.kt @@ -1,7 +1,6 @@ package swot -import kotlin.test.* -import junit.framework.* +import junit.framework.TestCase class SwotTest : TestCase() { fun testSwot() {