home.social

#testcoverage — Public Fediverse posts

Live and recent posts from across the Fediverse tagged #testcoverage, aggregated by home.social.

  1. 🚀 Now showing test coverage directly in class diagrams.

    No more guessing what's tested — it's all visual, right where you design.

    #DevTools #DX #TestCoverage #CodeDesign

  2. 🚀 Now showing test coverage directly in class diagrams.

    No more guessing what's tested — it's all visual, right where you design.

    #DevTools #DX #TestCoverage #CodeDesign

  3. My goal this week is to add at least 80% code coverage with unit tests for one fo my personally written apps. #developer #testcoverage

  4. C++ code coverage reports often omit function templates that are not instantiated, which can give a misleading picture of coverage. I've been trying to improve my tooling in this regard, and so added a feature to Doxide to export line data directly from source code that can be mixed in with gcov coverage data. Here's the story so far.

    indii.org/blog/cplusplus-code-

  5. One semi decent programming use case I have found for LLMs is starting out unit tests to backfill coverage for an already existing untested function.

    #dev #testcoverage

  6. Opinions on #unittesting are endless: test fixtures, test factories; test doubles, mocks, and stubs. The real problem is mistaking exhaustive #testcoverage for a sensible testing strategy. They aren't synonymous.

    Testing core #RubyLang methods or coupling tests for a menu bar to DB calls both miss the point. The Pareto principle is to validate *your* logic, not whether Ruby or Rails work.

    Tests that can't explain app-specific features or debug non-builtin code is *muda* waste. Just don't.

  7. @sourcenouveau if there is a gap in testing it should be easy to find, and possibly easy to fix, and I’d rather do that than write my own clone from scratch!

  8. What is an example of an open source system with an exceptionally good test suite?

    The example I gave today is #SQLite, with 100% branch coverage, MC/DC testing and 600 (!) test lines per line of code.

    - How SQLite is tested: sqlite.org/testing.html
    - MC/DC for SQLite: corecursive.com/066-sqlite-wit
    - SQLite architecture: vldb.org/pvldb/vol15/p3535-gaf

    #sqlite #mcdc #testcoverage

  9. #TestCoverage. 100% is too little. 80% is enough.

    My proof case is literally any language divide by 0.

    #python case
    def inverse(x):
    return 1 / x

    I’ve been scouring for an example of any “mainstream” programming language that handles this without putting the burden on the dev to remember, “Oh yeah! I need to write error handling for that.”

  10. I just wrote a which didn't improve my code's but was absolutely vital, and which many people don't bother with. I'm writing code to generate a report. I've got copious tests that make sure the reports contain all the correct info. I added a test that they don't include wrong info. Test that your code does what you want, but also test that it doesn't do what you don't want. can find very nasty bugs.

  11. I just wrote a #test which didn't improve my code's #TestCoverage but was absolutely vital, and which many people don't bother with. I'm writing code to generate a report. I've got copious tests that make sure the reports contain all the correct info. I added a test that they don't include wrong info. Test that your code does what you want, but also test that it doesn't do what you don't want. #NegativeTesting can find very nasty bugs.

  12. I just wrote a #test which didn't improve my code's #TestCoverage but was absolutely vital, and which many people don't bother with. I'm writing code to generate a report. I've got copious tests that make sure the reports contain all the correct info. I added a test that they don't include wrong info. Test that your code does what you want, but also test that it doesn't do what you don't want. #NegativeTesting can find very nasty bugs.

  13. I just wrote a #test which didn't improve my code's #TestCoverage but was absolutely vital, and which many people don't bother with. I'm writing code to generate a report. I've got copious tests that make sure the reports contain all the correct info. I added a test that they don't include wrong info. Test that your code does what you want, but also test that it doesn't do what you don't want. #NegativeTesting can find very nasty bugs.

  14. I just wrote a #test which didn't improve my code's #TestCoverage but was absolutely vital, and which many people don't bother with. I'm writing code to generate a report. I've got copious tests that make sure the reports contain all the correct info. I added a test that they don't include wrong info. Test that your code does what you want, but also test that it doesn't do what you don't want. #NegativeTesting can find very nasty bugs.

  15. The quality of tests tells more about the project than the #testcoverage.

  16. Everyone wants to add tools to the dev env, but nobody wants to support their team when they break the precommit hooks. #eslint #typescript #jest #tdd #danger #testCoverage #linting #husky