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

Add a command to run Test262 tests for spec conformance #18

Merged
merged 1 commit into from
Mar 3, 2023

Conversation

justingrant
Copy link
Contributor

@justingrant justingrant commented Dec 11, 2022

This PR fixes #3 by adding a new command yarn run test262 that runs 6000+ Temporal-related tests in Test262 (the TC39 spec-conformance test suite) against this repo's Temporal polyfill.

The current results are below. The good news: 3500+ tests pass! The bad news: 2700+ tests fail. ☹️

6302 tests finished in 16.0 s
  3584 passed
  2716 failed

Test262 files are checked in as a git submodule which will need to be updated periodically like all submodules.

I used the optimized test runner from the tc39/proposal-temporal repo, with only a few minor changes to adapt to this polyfill.

When running Test262 tests, terser is turned off for easier debugging and so that the test runner output doesn't emit indecipherable, long output when tests fail.

I also added a launch.json profile for debugging Test262 tests in VS Code. Something seems to be messed up with the sourcemap because when I break inside the debugger, the wrong line of code inside the polyfill is highlighted in the IDE. I wasn't sure if this was a pre-existing problem or not, so didn't try to fix it here.

I didn't check in yarn.lock with this PR because I had trouble getting the polyfill to build without upgrading yarn, and I was hesitant to check in those upgrades.

I also didn't include Test262 in the yarn test script that gates all PRs, because there's likely a lot of work required to get those 2700+ tests passing in the meantime.

Let me know how you'd like me to proceed with this PR!

This commit adds a new command `yarn run test262` that runs Temporal's
Test262 (the TC39 spec-conformance test suite) on this polyfill.
@arshaw
Copy link
Member

arshaw commented Dec 20, 2022

@justingrant I was a bit intimidated to hook-up all these tests, so thank you very much, this saves me a lot of time. Glad to hear the tests run faster.

Q1 of next year will be spent getting this polyfill to a production-ready state (now that v6 of fullcalendar is out). I'll keep in touch.

@justingrant
Copy link
Contributor Author

Sounds good. Feel free to reach out if you need anything.

@arshaw arshaw merged commit d27736b into fullcalendar:main Mar 3, 2023
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.

Should probably run Test262 against this polyfill
2 participants