fix: fix workflow #19
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Tests | |
| on: | |
| push: | |
| branches: [ main ] | |
| pull_request: | |
| branches: [ main ] | |
| workflow_dispatch: | |
| jobs: | |
| test: | |
| name: Test SwiftUI Query | |
| runs-on: macos-15 | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Show Swift version | |
| run: swift --version | |
| - name: Install SwiftLint | |
| run: brew install swiftlint | |
| - name: Lint Code | |
| run: make lint | |
| - name: Run Tests with Coverage | |
| run: swift test --parallel --enable-code-coverage | |
| - name: Generate Coverage Report | |
| run: | | |
| xcrun llvm-cov export \ | |
| .build/debug/swiftui-queryPackageTests.xctest/Contents/MacOS/swiftui-queryPackageTests \ | |
| -instr-profile=.build/debug/codecov/default.profdata \ | |
| -ignore-filename-regex=".build|Tests" \ | |
| -format="lcov" > coverage.lcov | |
| continue-on-error: true | |
| - name: Upload Coverage | |
| uses: codecov/codecov-action@v4 | |
| with: | |
| file: ./coverage.lcov | |
| fail_ci_if_error: false | |
| continue-on-error: true |