Migrate to new timezone database - Attempt #2 #135
Workflow file for this run
This file contains 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: Sugar Unit Tests | |
on: | |
push: | |
paths: | |
- .github/workflows/sugar_unit_test.yaml | |
- sugar/lib/** | |
- sugar/test/** | |
- sugar/tool/** | |
- sugar/analysis_options.yaml | |
- sugar/dart_test.yaml | |
- sugar/dartdoc_options.yaml | |
- sugar/pubspec.yaml | |
pull_request: | |
paths: | |
- .github/workflows/sugar_unit_test.yaml | |
- sugar/lib/** | |
- sugar/test/** | |
- sugar/tool/** | |
- sugar/analysis_options.yaml | |
- sugar/dart_test.yaml | |
- sugar/dartdoc_options.yaml | |
- sugar/pubspec.yaml | |
jobs: | |
test: | |
name: Unit tests | |
runs-on: ubuntu-latest | |
defaults: | |
run: | |
working-directory: sugar | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: subosito/[email protected] | |
- name: Install Node | |
uses: actions/setup-node@v4 | |
with: | |
node-version: "20" | |
- name: Install Java | |
uses: actions/setup-java@v4 | |
with: | |
distribution: "adopt" | |
java-version: "11.0.26+4" | |
- run: dart pub get | |
- run: dart analyze --fatal-warnings | |
- run: dart format . --set-exit-if-changed --output none | |
- run: dart run tool/generate_timezones.dart | |
- run: dart run coverage:test_with_coverage | |
- run: sudo apt-get update -y | |
- run: sudo apt-get install -y lcov | |
- run: lcov --remove ./coverage/lcov.info '**.g.dart' -o ./coverage/lcov.info | |
- uses: codecov/codecov-action@v5 | |
with: | |
files: ./sugar/coverage/lcov.info |