Skip to content

Commit 6dcf324

Browse files
committed
Fixed test.
Signed-off-by: Marcin Kuszczak <1508798+aartiPl@users.noreply.github.com>
1 parent f9d4a8f commit 6dcf324

2 files changed

Lines changed: 13 additions & 6 deletions

File tree

File renamed without changes.

src/integration/kotlin/io/github/kscripting/kscript/integration/ResolverTest.kt

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,21 +9,28 @@ import org.junit.jupiter.api.Test
99
import java.io.File
1010

1111
class ResolverTest : TestBase {
12-
1312
@Test
14-
@Tag("linux")
15-
@Tag("macos")
16-
@Tag("msys")
13+
@Tag("posix")
1714
@Tag("windows")
18-
fun `it should run kscript and resolve dependencies`() {
15+
fun `It should run kscript and resolve dependencies`() {
16+
// The first time artifact resolution is started because the cache is cleaned...
17+
verify(
18+
"kscript ${resolvePath("$projectDir/test/resources/depends_on_annot.kts")}",
19+
0,
20+
"kscript with annotations rocks!\n",
21+
startsWith("[kscript] Resolving log4j:log4j:1.2.14")
22+
)
23+
24+
1925
// clear .m2 cache
2026
val log4jCached = File(System.getProperty("user.home"), ".m2/repository/log4j/log4j/1.2.14/")
2127

2228
if (log4jCached.isDirectory) {
23-
System.err.println("Cleaning up cached .m2 copy of log4j")
29+
System.err.println("Cleaning up cached copy of log4j: ${log4jCached.absolutePath}")
2430
log4jCached.deleteRecursively()
2531
}
2632

33+
// The second time it is because of removing artifact from cache...
2734
verify(
2835
"kscript ${resolvePath("$projectDir/test/resources/depends_on_annot.kts")}",
2936
0,

0 commit comments

Comments
 (0)