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

chore: add more coverage tasks to deno.json #6395

Merged
merged 3 commits into from
Feb 12, 2025
Merged

Conversation

BlackAsLight
Copy link
Contributor

Nobody really asked for this type of change, but I have found it quite useful so hope it gets merged.

Essentially this change adds three new tasks to deno.json.

  • deno task cov:mac
  • deno task cov:lin
  • deno task cov:win

Calling the one for your respective system will go through the process of generating the coverage reports and then open it with whatever your default application is for html files. Most likely your browser.

This pull request also makes the change of removing doc examples from being included in the coverage seen as, from my point of view, the doc examples aren't meant to be proving the validity of the code.

@BlackAsLight BlackAsLight requested a review from kt3k as a code owner February 12, 2025 05:57
Copy link

codecov bot commented Feb 12, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 96.08%. Comparing base (b7c76d5) to head (98628d2).
Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #6395      +/-   ##
==========================================
- Coverage   96.11%   96.08%   -0.04%     
==========================================
  Files         557      558       +1     
  Lines       42156    42190      +34     
  Branches     6373     6375       +2     
==========================================
+ Hits        40520    40537      +17     
- Misses       1597     1614      +17     
  Partials       39       39              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

deno.json Outdated
@@ -24,10 +24,13 @@
"typos": "typos -c ./.github/workflows/typos.toml",
"build:crypto": "deno task --cwd crypto/_wasm wasmbuild",
"wasmbuild": "deno run -A jsr:@deno/[email protected] --js-ext mjs --sync",
"cov": "deno coverage --ignore=\"**/*.generated.mjs,**/_test_utils.ts,.github\"",
"cov": "deno task test --coverage --clean --reporter=dot && deno coverage --ignore=\"**/*.generated.mjs,**/_test_utils.ts,.github\"",
Copy link
Member

Choose a reason for hiding this comment

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

This seems causing the entire test cases run multiple times in CI. Can you also modify ci.yml to fix that?

Copy link
Member

@kt3k kt3k left a comment

Choose a reason for hiding this comment

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

This also reduces unnecessary coverage output in publish CI. Nice!

LGTM

@kt3k kt3k merged commit e5c0830 into denoland:main Feb 12, 2025
18 checks passed
@BlackAsLight BlackAsLight deleted the cov_tasks branch February 12, 2025 08:08
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.

2 participants