Skip to content

Commit

Permalink
Fix generating coverage report on GitHub actions
Browse files Browse the repository at this point in the history
  • Loading branch information
jonathangomz committed Jun 22, 2021
1 parent 4ff1202 commit ac2ee24
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
8 changes: 7 additions & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,15 +24,21 @@ jobs:
- name: Install dependencies
run: flutter pub get

- name: Activate coverage
run: pub global activate coverage

- name: Test package
run: flutter test --coverage
run: dart test --coverage=coverage
env:
TOKEN: ${{ secrets.TOKEN }}
TEST_DATABASE_ID: ${{ secrets.TEST_DATABASE_ID }}
TEST_PAGE_ID: ${{ secrets.TEST_PAGE_ID }}
TEST_BLOCK_ID: ${{ secrets.TEST_BLOCK_ID }}
EXEC_ENV: 'github_actions'

- name: Format coverage
run: pub global run coverage:format_coverage --lcov --in=coverage --out=coverage/lcov.info --packages=.packages --report-on=lib

- name: Upload coverge to Codecov
uses: codecov/codecov-action@v1
with:
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
env.dart
.env*
.vscode
coverage/

# Miscellaneous
*.class
Expand Down

0 comments on commit ac2ee24

Please sign in to comment.