Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upfeat: print coverage counters in the reporter #74
Conversation
return null | ||
// count current code coverage | ||
const counters = { | ||
s: 0, |
flotwig
Sep 10, 2019
Member
Instead of s, f, b
, could statements, functions, branches
be used instead? The short names are kinda obscure
bahmutov
Sep 10, 2019
Author
Contributor
good point, I will keep the one letter properties, since they match the coverage object properties, but will add comments
return | ||
} | ||
cy.task('combineCoverage', coverage).then(response => { | ||
cy.log(`**${response.covered.s}**/**${response.total.s}** statements`) |
flotwig
Sep 10, 2019
Member
A test that this cy.log
works as expected with the correct output would be nice to have, like in submit_spec
: https://github.com/cypress-io/cypress/blob/876fe5bbd890164e2bc901f5376cb69d0aaad583/packages/driver/test/cypress/integration/commands/actions/submit_spec.coffee#L168-L172
bahmutov
Sep 10, 2019
•
Author
Contributor
good observation about logs test, I might start creating test subfolders with test projects. It will be hard to test everything since most of the stuff happens after each or after all tests
To quickly see the coverage after each test
I think it looks kind of nice, here is TodoMVC