Skip to content

Conversation

@priethor
Copy link
Contributor

@priethor priethor commented Nov 20, 2025

What

Improves the project's CI to run JS unit tests in PRs and pushes to trunk.

Why

JS unit tests were recently added to the project, so it's good that we run them as part of the CI.

How

  • Adding a new GH workflow that runs on the minimum node version on PRs and node 20, 22, and 24 in trunk
  • Upload the coverage report to codecov; adapt the other CI workflows to put the coverage reports in different subfolders, so that local runs don't overwrite each other

@codecov
Copy link

codecov bot commented Nov 20, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 10.54%. Comparing base (0a774ff) to head (bfcf4e8).
⚠️ Report is 1 commits behind head on trunk.

Additional details and impacted files
@@             Coverage Diff              @@
##              trunk     #250      +/-   ##
============================================
- Coverage     10.97%   10.54%   -0.43%     
  Complexity     4284     4284              
============================================
  Files           266      279      +13     
  Lines         33139    34576    +1437     
============================================
+ Hits           3636     3645       +9     
- Misses        29503    30931    +1428     
Flag Coverage Δ
e2e 29.55% <0.00%> (-0.03%) ⬇️
javascript 0.26% <100.00%> (?)
phpunit 6.06% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@priethor priethor force-pushed the add/ci-workflow-for-unit-tests branch 2 times, most recently from 40f1336 to 5244233 Compare November 20, 2025 18:52
@priethor priethor force-pushed the add/ci-workflow-for-unit-tests branch from 5244233 to 47eedd5 Compare November 20, 2025 18:53
@priethor priethor marked this pull request as ready for review November 20, 2025 18:55
@github-actions
Copy link

github-actions bot commented Nov 20, 2025

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the props-bot label.

Core Committers: Use this line as a base for the props when committing in SVN:

Props priethor, cbravobernal.

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

Copy link
Contributor

@cbravobernal cbravobernal left a comment

Choose a reason for hiding this comment

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

Let's merge it.

@cbravobernal
Copy link
Contributor

We may need it to rebase, as I fixed the Placeholder error a while ago.

@priethor
Copy link
Contributor Author

priethor commented Dec 10, 2025

Yes, this branch needs updating with trunk and fixing some tests yet, I'll do it to help with the coverage in #253 (although it should not be a blocker for that PR)

@priethor priethor force-pushed the add/ci-workflow-for-unit-tests branch from 509794a to bfcf4e8 Compare December 10, 2025 14:08
@priethor
Copy link
Contributor Author

priethor commented Dec 10, 2025

@cbravobernal the JS failing test is fixed now; feel free to manually test and rebase #253 🚀

@priethor priethor merged commit 53b7351 into trunk Dec 10, 2025
9 checks passed
@priethor priethor deleted the add/ci-workflow-for-unit-tests branch December 10, 2025 14:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants