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

Code Coverage published to codecov.io #61

Merged
merged 7 commits into from
Apr 15, 2020
Merged

Code Coverage published to codecov.io #61

merged 7 commits into from
Apr 15, 2020

Conversation

kumare3
Copy link
Contributor

@kumare3 kumare3 commented Apr 15, 2020

TL;DR

The PR publishes test coverage report to codecov.io. This allows tracking every checkin and the code coverage over time

Type

  • Bug Fix
  • Feature
  • Plugin

Are all requirements met?

  • Code completed
  • Smoke tested
  • Unit tests added
  • Code documentation added
  • Any pending items have an associated Issue

Complete description

Same as TL;DR

Tracking Issue

flyteorg/flyte#260

Follow-up issue

NA

@codecov-io
Copy link

codecov-io commented Apr 15, 2020

Codecov Report

❗ No coverage uploaded for pull request base (master@6844b7a). Click here to learn what that means.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##             master      #61   +/-   ##
=========================================
  Coverage          ?   57.23%           
=========================================
  Files             ?      362           
  Lines             ?     5745           
  Branches          ?      789           
=========================================
  Hits              ?     3288           
  Misses            ?     2457           
  Partials          ?        0           

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 6844b7a...9018891. Read the comment docs.

@kumare3 kumare3 requested a review from schottra April 15, 2020 04:08
@kumare3 kumare3 merged commit 3a57160 into master Apr 15, 2020

.PHONY: test_unit_codecov
test_unit_codecov: test_unit
npm install codecov -g
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should just be added to the project dependencies, not installed every time we run make. Also, we use yarn for dependency management. Using npm here will probably generate a separate lock file that is incompatible with our yarn lockfile.

.PHONY: test_unit_codecov
test_unit_codecov: test_unit
npm install codecov -g
codecov -f .coverage/coverage-final.json
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This doesn't appear to actually run the unit tests anymore, just generates code coverage. I think we need something like yarn test && yarn run codecov.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nvmd, I missed that it has a dependency on the other make target

@@ -20,7 +20,7 @@
"start": "node -r dotenv/config index.js",
"storybook": "start-storybook -p 9001 -c .storybook",
"tdd": "yarn run test --watch --verbose false",
"test": "NODE_ENV=test jest --config=jest.config.js"
"test": "NODE_ENV=test jest --coverage --config=jest.config.js"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Generating coverage is a lot slower than just running the tests. I would recommend we create a separate script here just to run code coverage, and not run it every time unit tests are run.

@schottra schottra deleted the coverage branch April 15, 2020 22:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants