Skip to content

Commit

Permalink
chore: throw more threads at dart test
Browse files Browse the repository at this point in the history
  • Loading branch information
td-famedly committed Dec 20, 2023
1 parent 5d892a8 commit 43ba0a6
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions scripts/test.sh
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
#!/bin/bash

thread_count=$(getconf _NPROCESSORS_ONLN)

if which flutter >/dev/null; then
flutter pub global activate junitreport
flutter test --coverage
flutter test --concurrency=$thread_count --coverage --file-reporter='json:TEST-report.json'
TEST_CODE=$?

# coverage
flutter pub global activate remove_from_coverage
flutter pub global run remove_from_coverage:remove_from_coverage -f coverage/lcov.info -r '\.g\.dart$'
else
dart test --coverage=coverage
dart test --file-reporter='json:TEST-report.json'
dart test --concurrency=$thread_count --coverage=coverage --file-reporter='json:TEST-report.json'
TEST_CODE=$?

# coverage -> broken see https://github.com/dart-lang/test/issues/1698
Expand Down

0 comments on commit 43ba0a6

Please sign in to comment.