From 87ff422b66648535c7bd212c8880678d0ff31354 Mon Sep 17 00:00:00 2001 From: Kristian Nedrevold-Hansen Date: Thu, 19 Dec 2024 12:10:26 +0100 Subject: [PATCH] Added bsp link test for native 0.4 --- .../test/scala/bloop/bsp/BspLinkSpec.scala | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/frontend/src/test/scala/bloop/bsp/BspLinkSpec.scala b/frontend/src/test/scala/bloop/bsp/BspLinkSpec.scala index 9d1c9489c..9126513a5 100644 --- a/frontend/src/test/scala/bloop/bsp/BspLinkSpec.scala +++ b/frontend/src/test/scala/bloop/bsp/BspLinkSpec.scala @@ -13,7 +13,24 @@ class BspLinkSpec( override val protocol: BspProtocol ) extends BspBaseSuite { - test("can link scala-native cross project") { + test("can link scala-native-04 cross project") { + TestUtil.withinWorkspace { workspace => + val logger = new RecordingLogger(ansiCodesSupported = false) + loadBspBuildFromResources(s"cross-test-build-scala-native-0.4", workspace, logger) { build => + val project: TestProject = build.projectFor("test-projectNative") + val compiledState = + build.state.compile(project, arguments = Some(List("--link"))) + assertEquals(compiledState.status, ExitStatus.Ok) + assert( + logger + .getMessagesAt(level = Some("info")) + .find(_.contains("Generated native binary")) + .size == 1 + ) + } + } + } + test("can link scala-native-05 cross project") { TestUtil.withinWorkspace { workspace => val logger = new RecordingLogger(ansiCodesSupported = false) loadBspBuildFromResources(s"cross-test-build-scala-native-0.5", workspace, logger) { build =>