Skip to content

tools: support environment variables via comments #58186

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

Conversation

pmarchini
Copy link
Member

It should address #58179 by adding support for environment variables via comments.
I've not run the entire test suite, only a subset.
A full CI run will be needed to catch any potential regressions!

@nodejs-github-bot nodejs-github-bot added needs-ci PRs that need a full CI run. test Issues and PRs related to the tests. tools Issues and PRs related to the tools directory. labels May 5, 2025
Copy link
Contributor

@cjihrig cjihrig left a comment

Choose a reason for hiding this comment

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

JS portion LGTM.

@pmarchini
Copy link
Member Author

I've already seen a bunch of regressions, changing the method signature may not have been the best decision(I'm trying to avoid reading the test file twice)
I'll have another look ASAP!

@pmarchini pmarchini force-pushed the feat/py_test_runner/support_env_notation branch from 830bb71 to d674f42 Compare May 5, 2025 22:29
Copy link

codecov bot commented May 5, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 90.17%. Comparing base (4acb854) to head (dfeec6e).
Report is 297 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #58186      +/-   ##
==========================================
+ Coverage   90.15%   90.17%   +0.02%     
==========================================
  Files         630      629       -1     
  Lines      186756   186643     -113     
  Branches    36648    36651       +3     
==========================================
- Hits       168362   168306      -56     
+ Misses      11193    11133      -60     
- Partials     7201     7204       +3     

see 50 files with indirect coverage changes

🚀 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.

@pmarchini pmarchini force-pushed the feat/py_test_runner/support_env_notation branch from d674f42 to 77e4612 Compare May 6, 2025 07:48
@@ -0,0 +1,16 @@
'use strict';

// Environment Variables: A_SET_ENV_VAR=A_SET_ENV_VAR_VALUE B_SET_ENV_VAR=B_SET_ENV_VAR_VALUE
Copy link
Member

Choose a reason for hiding this comment

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

Just a nit but I'd prefer the more compact: // Env: ...

Copy link
Member Author

Choose a reason for hiding this comment

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

+1 (@joyeecheung suggested the same name)
I’ll go ahead and update the PR

Copy link
Member Author

Choose a reason for hiding this comment

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

done!

@pmarchini pmarchini force-pushed the feat/py_test_runner/support_env_notation branch from 77e4612 to dfeec6e Compare May 8, 2025 15:37
@pmarchini pmarchini added the request-ci Add this label to start a Jenkins CI on a PR. label May 9, 2025
@github-actions github-actions bot removed the request-ci Add this label to start a Jenkins CI on a PR. label May 9, 2025
@nodejs-github-bot
Copy link
Collaborator

@pmarchini pmarchini added the commit-queue Add this label to land a pull request using GitHub Actions. label May 11, 2025
@nodejs-github-bot nodejs-github-bot removed the commit-queue Add this label to land a pull request using GitHub Actions. label May 11, 2025
@nodejs-github-bot nodejs-github-bot merged commit 6184730 into nodejs:main May 11, 2025
60 checks passed
@nodejs-github-bot
Copy link
Collaborator

Landed in 6184730

targos pushed a commit that referenced this pull request May 16, 2025
PR-URL: #58186
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
@aduh95 aduh95 added the backport-requested-v22.x PRs awaiting manual backport to the v22.x-staging branch. label Jun 10, 2025
@aduh95
Copy link
Contributor

aduh95 commented Jun 10, 2025

Added tests are failing when cherry-picked on v22.x-staging, it will require a manual backport if we want it there

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport-requested-v22.x PRs awaiting manual backport to the v22.x-staging branch. needs-ci PRs that need a full CI run. test Issues and PRs related to the tests. tools Issues and PRs related to the tools directory.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants