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
[testharness.js] introduce assert_precondition
#19993
Conversation
4fdb848
to
3e9e171
Compare
https://wpt.fyi/results/vibration/invalid-values.html?diff&filter=ADC&run_id=344870003&run_id=344860005 shows that this had the intended effect for one test at least. |
392bfd3
to
fa5e45b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bringing a detail to the attention of RFC reviewers coming from web-platform-tests/rfcs#16 (comment).
@@ -3671,16 +3692,19 @@ policies and contribution forms [3]. | |||
var tests = new Tests(); | |||
|
|||
if (global_scope.addEventListener) { | |||
var error_handler = function(message, stack) { | |||
var error_handler = function(error, message, stack) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There might be reasonable disagreement to be had about this one, whether an unwrapped precondition_failed
should be an error or not. And also whether it really makes sense for allow_uncaught_exception
to allow failing asserts as is currently the case.
resources/testharness.js
Outdated
@@ -792,8 +792,10 @@ policies and contribution forms [3]. | |||
|
|||
function done() { | |||
if (tests.tests.length === 0) { | |||
tests.status.status = tests.status.ERROR; | |||
tests.status.message = "done() was called without first defining any tests"; | |||
if (tests.status.status === null) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This extra check is a workaround for #20036 (comment) but it might change, I'll use whatever change @jugglinmike lands to fix it.
c223650
to
c03ce9b
Compare
With #20168 now merged I'll rebase this. |
This depends on mozlog 5.0 for the new PRECONDITION_FAILED status: https://bugzilla.mozilla.org/show_bug.cgi?id=1589056 Implements web-platform-tests/rfcs#16. Includes parts of #16689. Fixes #19844.
This demonstrates the use of `assert_precondition` for subtests.
d9f0280
to
f378614
Compare
Alright, given no concerns voices about the behavior of a bare |
Address upstream WPT test harness changes web-platform-tests/wpt#19449 and web-platform-tests/wpt#19993 caused some of our proprietary tests to silently start to fail. This addresses all of the breakage.
Address upstream WPT test harness changes web-platform-tests/wpt#19449 and web-platform-tests/wpt#19993 caused some of our proprietary tests to silently start to fail. This addresses all of the breakage.
Address upstream WPT test harness changes web-platform-tests/wpt#19449 and web-platform-tests/wpt#19993 caused some of our proprietary tests to silently start to fail. This addresses all of the breakage.
Address upstream WPT test harness changes web-platform-tests/wpt#19449 and web-platform-tests/wpt#19993 caused some of our proprietary tests to silently start to fail. This addresses all of the breakage.
Address upstream WPT test harness changes web-platform-tests/wpt#19449 and web-platform-tests/wpt#19993 caused some of our proprietary tests to silently start to fail. This addresses all of the breakage.
Address upstream WPT test harness changes web-platform-tests/wpt#19449 and web-platform-tests/wpt#19993 caused some of our proprietary tests to silently start to fail. This addresses all of the breakage.
Address upstream WPT test harness changes web-platform-tests/wpt#19449 and web-platform-tests/wpt#19993 caused some of our proprietary tests to silently start to fail. This addresses all of the breakage.
This depends on mozlog 5.0 for the new PRECONDITION_FAILED status:
https://bugzilla.mozilla.org/show_bug.cgi?id=1589056
Implements web-platform-tests/rfcs#16.
Includes parts of #16689.
Fixes #19844.