Giter Site home page Giter Site logo

Comments (3)

bahmutov avatar bahmutov commented on June 11, 2024

You would need to include all expected files in the report by setting nyc object, see https://github.com/cypress-io/code-coverage#include-code

from instrument-cra.

brightpixels avatar brightpixels commented on June 11, 2024

That works. Thanks. Is it possible that the coverage percentage also accounts for untested lines of code in files that aren't used/imported anywhere like List.js in image below? This would prompt devs to either test the file or remove it as it's no longer needed.

PixelSnap 2021-01-08 at 19 05 20@2x

PixelSnap 2021-01-08 at 18 50 28@2x

from instrument-cra.

bahmutov avatar bahmutov commented on June 11, 2024

@brightpixels see https://github.com/cypress-io/code-coverage#contributing - nyc report is very forgiving and ignores empty files, but you can use https://github.com/bahmutov/check-code-coverage to check it and fail the test if any files are not covered

from instrument-cra.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.