VeryGoodOpenSource / very_good_test_runner

A test runner for Flutter and Dart created by Very Good Ventures 🦄
https://pub.dev/packages/very_good_test_runner
MIT License
18 stars 3 forks source link

fix: exclude specific folders from coverage #26

Open stact opened 3 months ago

stact commented 3 months ago

Description Hi team, we are not able exclude folders from coverage, I don't know if it's a bug, or For instance we have generated folder that include our localization

`very_good test --coverage --exclude-coverage "lib/l10n/**"``

Steps To Reproduce

  1. On your project folder create dummy folder with some dart files
  2. Open a terminal
  3. "cd" to your flutter project folder
  4. Launch the coverage very_good test --coverage --exclude-coverage "lib/l10n/**"
  5. See the results of the coverage (using vscode flutter coverage extension)

Expected Behavior The folder excluded must be ignored for coverage

Screenshots image

Additional Context Tried also to ignore files directly it's not working too

tomarra commented 1 month ago

Hi @stact 👋 thanks for opening this issue. From a quick glance at this we were able to reproduce this so were going to look into the --exclude-coverage flag and it's implementation.

We are always willing to let contributors help with fixes as well. Would you be willing to help with this?

stact commented 1 month ago

Hi @tomarra thank you for reaching out Unfortunately my knowledge is limited regarding coverage. I was looking in the past some alternative, maybe this PR can help to adapt the vg test https://github.com/dart-lang/coverage/pull/496