зеркало из https://github.com/mozilla/gecko-dev.git
bug 1579864: wpt: fix negation of wptrunner success indicator; r=jgraham
wptrunner.start() negates the return value of wptrunner.run() so that false is used to indicate that the test run was successful. This is then (wrongly) negated again by WebPlatformTestsRunner.run() and coerced into an integer. Quick demonstration: >>> unexpected_total = 0 >>> run_tests_rv = unexpected_total == 0 >>> start_rv = not run_tests_rv >>> run_rv = int(not start_rv) >>> run_rv 1 This causes git-bisect(1) (specifically "git bisect run ./mach wpt") to not work because it relies on the exit code to tell if a commit is good or bad. This patch offers the least invasive fix for the problem by not altering the API of the wptrunner test harness. Differential Revision: https://phabricator.services.mozilla.com/D45190 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
59aed5845a
Коммит
f5d787c5c9
|
@ -38,7 +38,7 @@ class WebPlatformTestsRunner(object):
|
|||
else:
|
||||
raise ValueError("Unknown product %s" % kwargs["product"])
|
||||
result = wptrunner.start(**kwargs)
|
||||
return int(not result)
|
||||
return int(result)
|
||||
|
||||
def update_manifest(self, logger, **kwargs):
|
||||
import manifestupdate
|
||||
|
|
Загрузка…
Ссылка в новой задаче