@@ -198,21 +198,11 @@ final class CodeLensTests: XCTestCase {
198198
199199 let project = try await SwiftPMTestProject (
200200 files: [
201- " Sources/MyApp /Test.swift " : """
201+ " Sources/MyLibrary /Test.swift " : """
202202 import Playgrounds
203203 1️⃣#Playground { print( " Hello Playground! " ) }2️⃣; 3️⃣#Playground { print( " Hello Again! " ) }4️⃣
204204 """
205205 ] ,
206- manifest: """
207- // swift-tools-version: 5.7
208-
209- import PackageDescription
210-
211- let package = Package(
212- name: " MyApp " ,
213- targets: [.executableTarget(name: " MyApp " )]
214- )
215- """ ,
216206 capabilities: capabilities,
217207 toolchainRegistry: toolchainRegistry
218208 )
@@ -229,11 +219,11 @@ final class CodeLensTests: XCTestCase {
229219 CodeLens (
230220 range: positions [ " 1️⃣ " ] ..< positions [ " 2️⃣ " ] ,
231221 command: Command (
232- title: #"Play "MyApp /Test.swift:2:1""# ,
222+ title: #"Play "MyLibrary /Test.swift:2:1""# ,
233223 command: " swift.play " ,
234224 arguments: [
235225 TextDocumentPlayground (
236- id: " MyApp /Test.swift:2:1" ,
226+ id: " MyLibrary /Test.swift:2:1" ,
237227 label: nil ,
238228 range: positions [ " 1️⃣ " ] ..< positions [ " 2️⃣ " ] ,
239229 ) . encodeToLSPAny ( )
@@ -243,11 +233,11 @@ final class CodeLensTests: XCTestCase {
243233 CodeLens (
244234 range: positions [ " 3️⃣ " ] ..< positions [ " 4️⃣ " ] ,
245235 command: Command (
246- title: " Play \" MyApp /Test.swift:2:46\" " ,
236+ title: " Play \" MyLibrary /Test.swift:2:46\" " ,
247237 command: " swift.play " ,
248238 arguments: [
249239 TextDocumentPlayground (
250- id: " MyApp /Test.swift:2:46" ,
240+ id: " MyLibrary /Test.swift:2:46" ,
251241 label: nil ,
252242 range: positions [ " 3️⃣ " ] ..< positions [ " 4️⃣ " ] ,
253243 ) . encodeToLSPAny ( )
@@ -344,7 +334,7 @@ final class CodeLensTests: XCTestCase {
344334 let toolchainRegistry = ToolchainRegistry ( toolchains: [ toolchainWithSwiftPlay] )
345335 let project = try await SwiftPMTestProject (
346336 files: [
347- " MyLib .swift" : """
337+ " Sources/MyLibrary/Test .swift" : """
348338 public func foo() -> String {
349339 " bar "
350340 }
@@ -372,7 +362,7 @@ final class CodeLensTests: XCTestCase {
372362 toolchainRegistry: toolchainRegistry
373363 )
374364
375- let ( uri, _) = try project. openDocument ( " MyLib .swift" )
365+ let ( uri, _) = try project. openDocument ( " Test .swift" )
376366 let response = try await project. testClient. send (
377367 CodeLensRequest ( textDocument: TextDocumentIdentifier ( uri) )
378368 )
@@ -388,7 +378,7 @@ final class CodeLensTests: XCTestCase {
388378 let toolchainRegistry = ToolchainRegistry ( toolchains: [ toolchainWithSwiftPlay] )
389379 let project = try await SwiftPMTestProject (
390380 files: [
391- " MyLib .swift" : """
381+ " Sources/MyLibrary/Test .swift" : """
392382 import Playgrounds
393383
394384 public func Playground(_ i: Int, _ j: Int) -> Int {
@@ -405,7 +395,7 @@ final class CodeLensTests: XCTestCase {
405395 toolchainRegistry: toolchainRegistry
406396 )
407397
408- let ( uri, _) = try project. openDocument ( " MyLib .swift" )
398+ let ( uri, _) = try project. openDocument ( " Test .swift" )
409399 let response = try await project. testClient. send (
410400 CodeLensRequest ( textDocument: TextDocumentIdentifier ( uri) )
411401 )
0 commit comments