Skip to content

Feature/improve access level #181

Feature/improve access level

Feature/improve access level #181

Workflow file for this run

name: Build and Test
on:
push:
branches: [ main ]
paths:
- 'Sources/**.swift'
- 'Tests/**.swift'
- 'Package.swift'
- 'Package.resolved'
- '.github/workflows/build.yml'
pull_request:
paths:
- 'Sources/**.swift'
- 'Tests/**.swift'
- 'Package.swift'
- 'Package.resolved'
- '.github/workflows/build.yml'
concurrency:
group: test_${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
runs-on: macos-15
steps:
- uses: actions/checkout@v4
- name: Select Xcode
run: sudo xcode-select -s /Applications/Xcode_16.2.app
- name: Cache .build
uses: actions/cache@v4.2.1
with:
path: .build
key: ${{ runner.os }}-spm-${{ hashFiles('**/Package.resolved') }}
restore-keys: |
${{ runner.os }}-spm-
- name: Build
run: swift build --verbose
- name: Run tests
run: swift test --verbose --enable-swift-testing --enable-code-coverage | xcbeautify --renderer github-actions --report junit
# - name: Upload test results to Codecov // Not working yet with Swift Testing
# uses: codecov/test-results-action@v1
# with:
# files: build/reports/junit.xml
# token: ${{ secrets.CODECOV_TOKEN }}
- name: Generate coverage
run: ./.scripts/generate_coverage.sh
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v5
with:
files: info.lcov
fail_ci_if_error: true
token: ${{ secrets.CODECOV_TOKEN }}