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

[fetch] Opt-in to single-page test feature #19919

Merged

Conversation

jugglinmike
Copy link
Contributor

testharness.js was recently extended with an API to explicitly opt-in to
the "single page test" feature [1]. As per WPT RFC 28 [2], tests which
do not use this API and which do not declare any subtests will soon be
reported as a harness error.

Update the tests which previously opted in implicitly to use the new
API.

[1] #19449
[2] https://github.com/web-platform-tests/rfcs/blob/master/rfcs/single_test.md

@foolip
Copy link
Member

foolip commented Oct 26, 2019

@annevk can you review this one? I've been reviewing/merging a bunch of these, but I suspect you might have feedback on this one.

Copy link
Member

@annevk annevk left a comment

Choose a reason for hiding this comment

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

Seems fine, though most of these should probably be improved at some point.

@@ -31,6 +31,7 @@ <h1 id="header">Header example</h1>
</body>

<script>
setup({ single_test: true });
Copy link
Member

Choose a reason for hiding this comment

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

@jugglinmike I see that this and a few of the following are just sync tests, can you wrap them in test(() => { ... }) instead?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sure. I've added titles to those tests, as well

@foolip
Copy link
Member

foolip commented Oct 28, 2019

@jugglinmike I'll leave merging to you as you'll probably want to change the commit message.

testharness.js was recently extended with an API to explicitly opt-in to
the "single page test" feature [1]. As per WPT RFC 28 [2], tests which
do not use this API and which do not declare any subtests will soon be
reported as a harness error.

Update some tests which previously opted in implicitly to use the new
API. Update others to instead declare a single subtest (so that they are
no longer single-page tests).

[1] web-platform-tests#19449
[2] https://github.com/web-platform-tests/rfcs/blob/master/rfcs/single_test.md
@jugglinmike
Copy link
Contributor Author

Thanks, Philip. I do, indeed. The original version of this branch is available here. Merging now.

@jugglinmike jugglinmike merged commit ef85c0f into web-platform-tests:master Oct 30, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants