Comments (9)
@jacob314 for package:js
. Not familiar with the implementation of dart:js
in Dartium, but is it possible we're not generating hits in cases like this?
from coverage.
That case would be really hard to support in Dartium. The problem is in that behind the scenes Dartium is implementing TestMe with noSuchMethod so the "external int returnFive()" isn't really being called. I'd recommend ignoring external methods when tracking your code coverage. DDC should be a much better job at tracking code coverage across the dart-JS boundary.
from coverage.
@jacob314 What are you referring to with DDC?
from coverage.
https://github.com/dart-lang/dev_compiler
from coverage.
The current implementation of coverage puts any given line in one of three states:
- Hit
- Miss
- Not coverable
If we can't support marking external
lines as hit, we should at least ensure that they're not coming back as a miss.
@brettonfinch-wf can you clarify whether the line is coming back with a hit count of 0 (miss) or not included in the generated coverage at all (not coverable)?
from coverage.
The lines are coming back with a hit count of 0, my project uses CodeCov and it reports those lines as red (missed)
from coverage.
Alright - sounds like if it's going to be too painful to get Dartium fixed, in particular with DDC coming, then marking em as un-coverable sounds like the way to go for now. Thanks for confirming!
from coverage.
Alright, that sounds good to me, thanks for confirming this!
from coverage.
Closing as obsolete now that Dartium support is gone. dart-lang/test#36 tracks coverage for Dart for Web scenarios.
from coverage.
Related Issues (20)
- error generating .lcov "This file is deprecated. Tools should instead consume" HOT 1
- File gets removed from coverage wrongly when "// coverage:ignore-file" is used in Strings HOT 1
- Enhanced enums in Flutter don't get covered HOT 1
- Function inside function HOT 3
- Add a benchmark to github CI HOT 1
- Which license is used in this project? HOT 1
- Speed up --function-coverage
- Filter files using a command line flag HOT 8
- Running coverage in new flutter project HOT 1
- --test param throws error when args are added (--test="test --concurrency=1") HOT 1
- incorrect branch and line coverage with const values HOT 1
- Add `--fail-under` option
- LCOV relative paths HOT 1
- No Coverage Generated
- Fix BRDA syntax in lcov files HOT 3
- Enable firehose for publishing from GitHub actions
- Clean up old SDK/VmService checks
- Tests with `Isolate.run` pause indefinitely. HOT 6
- Ignore like `// coverage:ignore-start` does not work HOT 1
- bug: `format_coverage` does now work when invoked with `dart pub global run`
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from coverage.