-
Notifications
You must be signed in to change notification settings - Fork 225
Open
Labels
Description
When executing tests with coverage collection in a child package of a workspace, the coverage is always empty.
Steps to Reproduce
- Create an empty dart package
- Create a child package below that package
- Set
resolution: workspaceon the child package and addworkspace: [ "packages/<package-name>" ]to the parent - Run
dart pub getin the parent folder - Run
dart test --coverage=coveragein the child folder - Inspecting the created coverage files, you will see that they will all be empty like this:
{"type":"CodeCoverage","coverage":[]}
The same happens when using the new --coverage-path option.
Simply removing resolution: workspace and running dart pub get again will make it work again, but that is of course not a solution.
Sample project: cov_test_ws.zip
System Information
Dart version: 3.10.1
package:test Version: 1.25.6
Environments: Any. Happens in the CI and locally, for windows, macos and linux
felix-barz-brickmakers and mrverdant13