Added github workflow
This commit is contained in:
parent
190fde25e4
commit
dcd755e031
|
@ -0,0 +1,28 @@
|
||||||
|
name: Swift
|
||||||
|
|
||||||
|
on: [push]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
|
||||||
|
runs-on: macOS-latest
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
destination: ['platform=iOS Simulator,OS=13.1,name=iPhone 11']
|
||||||
|
xcode: ['/Applications/Xcode_12.app/Contents/Developer']
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v1
|
||||||
|
# Github Actions' machines do in fact have recent versions of Xcode,
|
||||||
|
# but you may have to explicitly switch to them. We explicitly want
|
||||||
|
# to use Xcode 12, so we use xcode-select to switch to it.
|
||||||
|
- name: Switch to Xcode 12
|
||||||
|
run: sudo xcode-select --switch /Applications/Xcode_12.app
|
||||||
|
# Since we want to be running our tests from Xcode, we need to
|
||||||
|
# generate an .xcodeproj file. Luckly, Swift Package Manager has
|
||||||
|
# build in functionality to do so.
|
||||||
|
- name: Generate xcodeproj
|
||||||
|
run: swift package generate-xcodeproj
|
||||||
|
# Finally, we invoke xcodebuild to run the tests on an iPhone 11
|
||||||
|
# simulator.
|
||||||
|
- name: Run tests
|
||||||
|
run: xcodebuild test -destination 'name=iPhone 11' -scheme 'ObjectUI-Package'
|
Loading…
Reference in New Issue