@@ -154,25 +154,6 @@ jobs:
154154 mkdir hello
155155 cd hello
156156 swiftly run swift package init --type executable
157-
158- if [[ "0" == "1" ]]; then
159- # make the contents a bit more interesting
160- cat > Sources/hello/hello.swift << "EOF"
161- import Foundation
162- import FoundationNetworking
163- import FoundationXML
164-
165- @main
166- struct hello {
167- static func main() async throws {
168- print("Hello, world!")
169- let (data, _) = try await URLSession.shared.data(from : URL(fileURLWithPath: "/etc/hosts"))
170- print(String(data : data, encoding: .utf8) ?? "")
171- }
172- }
173- EOF
174- fi
175-
176157 swiftly run swift build --swift-sdk "${ANDROID_EMULATOR_ARCH_TRIPLE}-unknown-linux-android${ANDROID_API}" --static-swift-stdlib
177158 file .build/debug/hello
178159
@@ -230,18 +211,34 @@ jobs:
230211 adb push $ANDROID_NDK_HOME/toolchains/llvm/prebuilt/*/sysroot/usr/lib/${ANDROID_EMULATOR_ARCH_TRIPLE}-linux-android/libc++_shared.so /data/local/tmp/
231212 adb shell /data/local/tmp/hello
232213
233- - name : Run Swift Package tests Android Emulator
214+ - name : Install testing prerequisites on Android Emulator
234215 run : |
235- git clone https://github.com/apple/swift-algorithms
236- cd swift-algorithms
237- swiftly run swift build --swift-sdk "${ANDROID_EMULATOR_ARCH_TRIPLE}-unknown-linux-android${ANDROID_API}" --build-tests
238-
239- adb push .build/debug/swift-algorithmsPackageTests.xctest /data/local/tmp
240-
241216 cd ~/Library/org.swift.swiftpm || cd ${XDG_CONFIG_HOME}/swiftpm || cd ~/.local/swiftpm || cd ~/.swiftpm
242217 # add necessary dependencies
243218 adb push swift-sdks/${SWIFT_ANDROID_SDK_VERSION}*.artifactbundle/swift-resources/usr/lib/swift-${ANDROID_EMULATOR_ARCH_TRIPLE}/android/*.so /data/local/tmp/
244219 cd -
245220
221+ - name : Run swift-algorithms tests on Android Emulator
222+ run : |
223+ git clone https://github.com/apple/swift-algorithms
224+ cd swift-algorithms
225+ swift build --swift-sdk "${ANDROID_EMULATOR_ARCH_TRIPLE}-unknown-linux-android${ANDROID_API}" --build-tests
226+ adb push .build/debug/swift-algorithmsPackageTests.xctest /data/local/tmp
246227 adb shell /data/local/tmp/swift-algorithmsPackageTests.xctest
247228
229+ - name : run swift-crypto tests on android emulator
230+ run : |
231+ git clone https://github.com/apple/swift-crypto
232+ cd swift-crypto
233+ swift build --swift-sdk "${android_emulator_arch_triple}-unknown-linux-android${android_api}" --build-tests
234+ adb push .build/debug/swift-cryptoPackageTests.xctest /data/local/tmp
235+ adb shell /data/local/tmp/swift-cryptoPackageTests.xctest
236+
237+ - name : run swift-argument-parser tests on android emulator
238+ run : |
239+ git clone https://github.com/apple/swift-argument-parser
240+ cd swift-argument-parser
241+ swift build --swift-sdk "${android_emulator_arch_triple}-unknown-linux-android${android_api}" --build-tests
242+ adb push .build/debug/swift-argument-parserPackageTests.xctest /data/local/tmp
243+ adb shell /data/local/tmp/swift-argument-parserPackageTests.xctest
244+
0 commit comments