Skip to content

Commit 0740830

Browse files
committed
Test both release and main
1 parent 7a37567 commit 0740830

File tree

1 file changed

+17
-20
lines changed

1 file changed

+17
-20
lines changed

.github/workflows/ci.yml

+17-20
Original file line numberDiff line numberDiff line change
@@ -15,35 +15,32 @@ jobs:
1515
#runs-on: macos-13
1616
runs-on: macos-12
1717
steps:
18-
- name: Create New Skip Package
18+
- name: Create New Skip Package (Release)
1919
run: |
20-
mkdir SomeLibrary
21-
cd SomeLibrary
22-
23-
swift package init
24-
25-
xcodebuild test -skipPackagePluginValidation -sdk "macosx" -destination "platform=macosx" -scheme SomeLibrary
20+
mkdir release
21+
cd release
22+
swift package init --name SomeLibrary
2623
2724
echo 'package.dependencies += [.package(url: "https://github.com/skiptools/skip", from: "0.0.0")]' >> Package.swift
2825
echo 'package.dependencies += [.package(url: "https://github.com/skiptools/skiphub", from: "0.0.0")]' >> Package.swift
2926
30-
#echo yes | swift package plugin skip-init
3127
swift package plugin --allow-writing-to-package-directory skip-init
32-
33-
# the artifact tool should be downloaded locally
34-
./.build/artifacts/skip/skiptool.artifactbundle/skiptool version
35-
3628
cat Package.swift Package.resolved
29+
swift test --configuration release
30+
brew install tree || true
31+
tree -l -I build
3732
38-
#xcodebuild test -skipPackagePluginValidation -sdk "macosx" -destination "platform=macosx" -scheme SomeLibraryKt
39-
40-
xcodebuild test -skipPackagePluginValidation -sdk "macosx" -destination "platform=macosx" -scheme SomeLibrary-Package
41-
42-
# add in an assertion failure to ensure the test now fails
43-
#echo 'extension SomeLibraryTests { func testFailure() { XCTAssertEqual(1, 2) } }' >> Tests/SomeLibraryTests/SomeLibraryTests.swift
33+
- name: Create New Skip Package (Debug)
34+
run: |
35+
mkdir debug
36+
cd debug
37+
swift package init --name SomeOtherLibrary
4438
45-
#xcodebuild test -skipPackagePluginValidation -sdk "macosx" -destination "platform=macosx" -scheme SomeLibrary-Package && false || true
39+
echo 'package.dependencies += [.package(url: "https://github.com/skiptools/skip", branch: "main")]' >> Package.swift
40+
echo 'package.dependencies += [.package(url: "https://github.com/skiptools/skiphub", branch: "main")]' >> Package.swift
4641
42+
swift package plugin --allow-writing-to-package-directory skip-init
43+
cat Package.swift Package.resolved
44+
swift test --configuration debug
4745
brew install tree || true
4846
tree -l -I build
49-

0 commit comments

Comments
 (0)