File tree Expand file tree Collapse file tree 2 files changed +48
-0
lines changed
Expand file tree Collapse file tree 2 files changed +48
-0
lines changed Original file line number Diff line number Diff line change 1+ name : CI
2+
3+ on :
4+ workflow_dispatch :
5+ push :
6+ branches :
7+ - main
8+ pull_request :
9+ branches :
10+ - ' *'
11+
12+ jobs :
13+ build-and-test :
14+ name : Build, Test, & Report Coverage
15+ runs-on : macos-latest
16+
17+ steps :
18+ - name : Checkout source code
19+ uses : actions/checkout@v4
20+
21+ - name : Set up Xcode
22+ uses : maxim-lobanov/setup-xcode@v1
23+ with :
24+ xcode-version : latest
25+
26+ - name : Install dependencies
27+ run : swift package resolve
28+
29+ - name : Build the package
30+ run : swift build
31+
32+ - name : Run tests with code coverage
33+ run : swift test --enable-code-coverage
34+
35+ - name : Gather code coverage
36+ run : xcrun llvm-cov export -format="lcov" .build/debug/SwiftSyntaxSugarPackageTests.xctest/Contents/MacOS/SwiftSyntaxSugarPackageTests -instr-profile .build/debug/codecov/default.profdata > coverage_report.lcov
37+
38+ - name : Upload coverage to Codecov
39+ uses : codecov/codecov-action@v5
40+ with :
41+ files : coverage_report.lcov
42+ token : ${{ secrets.CODECOV_TOKEN }}
43+ slug : fetch-rewards/SwiftSyntaxSugar
44+ verbose : true
45+ fail_ci_if_error : true
Original file line number Diff line number Diff line change 1+ coverage :
2+ ignore :
3+ - Tests/*
You can’t perform that action at this time.
0 commit comments