Skip to content

Commit

Permalink
Update configuration
Browse files Browse the repository at this point in the history
- Update the GitHub Actions CI script to enable testing on various platforms
  • Loading branch information
ns-vasilev committed Dec 31, 2023
1 parent e828dc4 commit c772e21
Showing 1 changed file with 67 additions and 23 deletions.
90 changes: 67 additions & 23 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,19 +48,13 @@ jobs:
name: "macOS 12, Xcode 14.1, Swift 5.7.1"
steps:
- uses: actions/checkout@v3
# - name: Install Dependencies
# run: make setup_build_tools
# - name: Generate project
# run: make generate
- name: ${{ matrix.name }}
run: swift build -v
# run: xcodebuild test CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO -scheme "Flare" -destination "platform=macOS" clean -enableCodeCoverage YES -resultBundlePath "./macos.xcresult" || exit 1
# - name: Upload coverage reports to Codecov
# uses: codecov/[email protected]
# with:
# token: ${{ secrets.CODECOV_TOKEN }}
# xcode: true
# xcode_archive_path: "./macos.xcresult"
run: xcodebuild test -scheme "Flare" -destination "platform=macOS" clean -enableCodeCoverage YES -resultBundlePath "./macos.xcresult" || exit 1
- name: Upload coverage reports to Codecov
uses: codecov/[email protected]
with:
token: ${{ secrets.CODECOV_TOKEN }}
xcode: true
xcode_archive_path: "./macos.xcresult"

iOS:
name: ${{ matrix.name }}
Expand All @@ -80,18 +74,14 @@ jobs:
name: "iOS 16.4"
xcode: "Xcode_14.3.1"
runsOn: macos-13
# - destination: "OS=15.5,name=iPhone 13 Pro"
# name: "iOS 15.5"
# xcode: "Xcode_13.4.1"
# runsOn: macOS-12
steps:
- uses: actions/checkout@v3
- name: Install Dependencies
run: make setup_build_tools
- name: Generate project
run: make generate
- name: ${{ matrix.name }}
run: xcodebuild test -scheme "Flare" -destination "${{ matrix.destination }}" clean -enableCodeCoverage YES -resultBundlePath "./iphonesimulator.xcresult" || exit 1
run: xcodebuild test -scheme "Flare" -destination "${{ matrix.destination }}" -testPlan AllTests clean -enableCodeCoverage YES -resultBundlePath "./iphonesimulator.xcresult" || exit 1
- name: Upload coverage reports to Codecov
uses: codecov/[email protected]
with:
Expand All @@ -117,25 +107,79 @@ jobs:
name: "tvOS 16.4"
xcode: "Xcode_14.3.1"
runsOn: macos-13
# - destination: "OS=15.4,name=Apple TV"
# name: "tvOS 15.4"
# xcode: "Xcode_13.4.1"
# runsOn: macos-12
steps:
- uses: actions/checkout@v3
- name: Install Dependencies
run: make setup_build_tools
- name: Generate project
run: make generate
- name: ${{ matrix.name }}
run: xcodebuild test -scheme "Flare" -destination "${{ matrix.destination }}" clean -enableCodeCoverage YES -resultBundlePath "./appletvsimulator.xcresult" || exit 1
run: xcodebuild test -scheme "Flare" -destination "${{ matrix.destination }}" -testPlan AllTests clean -enableCodeCoverage YES -resultBundlePath "./appletvsimulator.xcresult" || exit 1
- name: Upload coverage reports to Codecov
uses: codecov/[email protected]
with:
token: ${{ secrets.CODECOV_TOKEN }}
xcode: true
xcode_archive_path: "./appletvsimulator.xcresult"

watchOS:
name: ${{ matrix.name }}
runs-on: ${{ matrix.runsOn }}
env:
DEVELOPER_DIR: "/Applications/${{ matrix.xcode }}.app/Contents/Developer"
timeout-minutes: 20
strategy:
fail-fast: false
matrix:
include:
- destination: "OS=10.0,name=Apple Watch Series 9 (45mm)"
name: "watchOS 10.0"
xcode: "Xcode_15.0"
runsOn: macos-13
- destination: "OS=9.4,name=Apple Watch Series 8 (45mm)"
name: "watchOS 9.4"
xcode: "Xcode_14.3.1"
runsOn: macos-13
- destination: "OS=8.5,name=Apple Watch Series 7 (45mm)"
name: "watchOS 8.5"
xcode: "Xcode_14.3.1"
runsOn: macos-13
steps:
- uses: actions/checkout@v3
- name: Install Dependencies
run: make setup_build_tools
- name: Generate project
run: make generate
- name: ${{ matrix.name }}
run: xcodebuild test -scheme "Flare" -destination "${{ matrix.destination }}" -testPlan UnitTests clean -enableCodeCoverage YES -resultBundlePath "./watchsimulator.xcresult" || exit 1
- name: Upload coverage reports to Codecov
uses: codecov/[email protected]
with:
token: ${{ secrets.CODECOV_TOKEN }}
xcode: true
xcode_archive_path: "./watchsimulator.xcresult"

spm:
name: ${{ matrix.name }}
runs-on: ${{ matrix.runsOn }}
env:
DEVELOPER_DIR: "/Applications/${{ matrix.xcode }}.app/Contents/Developer"
timeout-minutes: 20
strategy:
fail-fast: false
matrix:
include:
- name: "Xcode 15"
xcode: "Xcode_15.0"
runsOn: macos-13
- name: "Xcode 14"
xcode: "Xcode_14.3.1"
runsOn: macos-13
steps:
- uses: actions/checkout@v3
- name: ${{ matrix.name }}
run: swift build -c release --target Flare

# Beta:
# name: ${{ matrix.name }}
# runs-on: firebreak
Expand Down

0 comments on commit c772e21

Please sign in to comment.