Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improved test suite #1820

Merged
merged 15 commits into from Jan 14, 2019
Merged

Improved test suite #1820

merged 15 commits into from Jan 14, 2019

Conversation

leo
Copy link
Contributor

@leo leo commented Jan 10, 2019

This PR finally makes nyc track all the source files for code coverage and adds many new unit tests in order to bring the coverage up.


Furthermore, it removes the following code paths that were never executed at all:

  • 7049b37 (furher above in the code, there's a check for whitelist and this check already captures all the properties that were checked for down below)
  • 0d67dc5 (further above in the code, we already make nowConfig match pkg.now if it is set)

@codecov-io
Copy link

codecov-io commented Jan 10, 2019

Codecov Report

Merging #1820 into canary will decrease coverage by 71.71%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           canary   #1820       +/-   ##
==========================================
- Coverage   77.52%   5.81%   -71.72%     
==========================================
  Files           6     100       +94     
  Lines         267    4247     +3980     
==========================================
+ Hits          207     247       +40     
- Misses         60    4000     +3940
Impacted Files Coverage Δ
src/util/config/local-path.js 100% <ø> (+16.66%) ⬆️
src/util/read-metadata.js 100% <100%> (+23.45%) ⬆️
src/util/get-files.js 91.53% <100%> (+11.99%) ⬆️
src/util/combine-async-generators.js 0% <0%> (ø)
src/util/output/format-log-output.js 0% <0%> (ø)
src/commands/logout.js 0% <0%> (ø)
src/util/is-zeit-world.js 0% <0%> (ø)
src/util/deploy/get-events-stream.js 0% <0%> (ø)
src/commands/billing/add.js 0% <0%> (ø)
src/commands/certs/rm.js 0% <0%> (ø)
... and 91 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3e74114...d40314e. Read the comment docs.

@leo leo requested review from OlliV and removed request for OlliV January 10, 2019 20:30
@leo leo requested a review from AndyBitz January 14, 2019 20:33
@AndyBitz AndyBitz merged commit 28df25e into canary Jan 14, 2019
@AndyBitz AndyBitz deleted the tests branch January 14, 2019 20:53
leo added a commit that referenced this pull request Jan 15, 2019
* Bumped `@zeit/ncc` to latest

* Reverted lockfile

* Make linking build for dev

* Cover line 21 in util/config/local-path.js

* Heavily improved unit test coverage

* Fixed space

* Got to 90% coverage

* Removed useless code

* Made builds work

* Fixed a few lines

* Fully covered read-metadata.js

* Brought coverage to 95.38

* Removed code that was never executed

* Track everything

* Don't show badge for now
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants