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

Easier debugging and troubleshooting of Test262 tests #1812

Merged
merged 1 commit into from
Sep 14, 2021

Conversation

justingrant
Copy link
Collaborator

@justingrant justingrant commented Sep 9, 2021

This PR enables running Test262 in debuggers like VSCode:

  • Adds a TIMEOUT environment variable (in msecs) to prevent the harness from killing the process while you're debugging it. Default is 10,000ms === 10 seconds. (same as existing default)
  • Works around a problem where passing tests were mistakenly labelled as failures when run in the debugger because of Node's debug-related console output.

js-temporal/temporal-polyfill#46 depends on this PR to work properly.

@codecov
Copy link

codecov bot commented Sep 9, 2021

Codecov Report

Merging #1812 (fc2e24c) into main (899cc24) will increase coverage by 0.00%.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #1812   +/-   ##
=======================================
  Coverage   94.96%   94.96%           
=======================================
  Files          19       19           
  Lines       10960    10963    +3     
  Branches     1740     1740           
=======================================
+ Hits        10408    10411    +3     
  Misses        537      537           
  Partials       15       15           
Flag Coverage Δ
test262 78.81% <ø> (+0.03%) ⬆️
tests 90.12% <ø> (+<0.01%) ⬆️

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

Impacted Files Coverage Δ
polyfill/lib/calendar.mjs 94.44% <0.00%> (+<0.01%) ⬆️

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 899cc24...fc2e24c. Read the comment docs.

@justingrant justingrant force-pushed the customize-262-tests branch 3 times, most recently from bc1f3c3 to b503a6d Compare September 9, 2021 23:49
@justingrant justingrant changed the title Environment variable to run a subset of Test262 tests Easier debugging and troubleshooting of Test262 tests Sep 10, 2021
@Ms2ger
Copy link
Collaborator

Ms2ger commented Sep 10, 2021

npm run test262 -- */prototype/subtract/* already works.

This commit enables running Test262 in debuggers like VSCode:
* Adds a TIMEOUT environment variable (in msecs) to prevent the harnesss
  from killing the process while you're debugging it.
  Default is 10,000ms === 10 seconds. (same as existing default)
* Works around a problem where passing tests were mistakenly labelled
  as failures when run in the debugger because of Node's debug-related
  console output.

js-temporal/temporal-polyfill#46 requires this.
@justingrant
Copy link
Collaborator Author

npm run test262 -- */prototype/subtract/* already works.

Oh! I reverted that change and updated js-temporal/temporal-polyfill#46 to use the CLI parameter instead of an environment variable. Works great. One of these days I'll really have to learn more about UNIX shell scripting syntax. 😄

The other remaining changes in this PR are still needed to unblock js-temporal/temporal-polyfill#46.

@Ms2ger Ms2ger merged commit eefeba6 into tc39:main Sep 14, 2021
@ptomato ptomato added the no-spec-text PR can be ignored by implementors label Sep 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
no-spec-text PR can be ignored by implementors
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants