question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Help wanted to reach ~100% code coverage

See original GitHub issue

As discussed in #1374 and elsewhere, our current milestone is to reach close to 100% coverage on the beta branch. With 100% test coverage, the tests take on a life of their own in maintaining the project, and will allow us to refactor – and add functionality – with confidence.

@jlilja, @gr2m and I conducted a line-by-line triage and added 46 comments marked TODO-coverage in #1375 and #1380. These are all the spots in the code where work on this milestone is needed.

As of right now we’re down to 40, so we’re 13% of the way there!

You can help!

  1. Look in the beta branch for TODO-coverage.
  2. Pick a todo or a file to start working on.
  3. Post here, so we don’t duplicate any work.
  4. When you’re ready, open your pull request on the beta branch.

One bit of guidance: our test strategy is to avoid narrow-bracket tests, and instead aim to keep writing high-level functional tests (i.e. via calls to nock()). If there is not a way to exercise the code through the public nock API, it may be dead code. In the case of dead code, it’s better to remove it than to add tests.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:1
  • Comments:21 (19 by maintainers)

github_iconTop GitHub Comments

3reactions
RichardLittcommented, Feb 14, 2019

Thank you so much, @paulmelnikow! I’ll grab a couple. Perhaps we should schedule another open source friday hackathon, too?

2reactions
gr2mcommented, Jul 18, 2019

WOW OMG WOW GREAT WORK @paulmelnikow & @mastermatt 💐🏅💐🏅

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to achieve 100% code coverage - Blog - Info Support
According to Uncle Bob, 100% test coverage is a minimum requirement. In our industy, that is a pretty bold goal, as usually 80%...
Read more >
How to Achieve 100% Code Coverage in Golang Unit Test?
However, achieving 100% code coverage on a unit test is tricky and difficult. You could achieve this if and only if you understand...
Read more >
100% CODE COVERAGE - think you're done? Think AGAIN.
The "holy grail" of unit testing is to reach 100 % code coverage. However, code coverage is not a perfect metric, as you'll...
Read more >
The myth of 100% code coverage - Functionize
Ask what code coverage should devs aim at, and many will say 100%. In this blog, we explain why this mythical goal can...
Read more >
The Dangerous Myth of 100% Code Coverage
Have you heard the commandment of the unit testing crowds? We must achieve enlightenment. We must achieve 100% code coverage!
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found