-
Notifications
You must be signed in to change notification settings - Fork 10.3k
Modernize the test driver #14344
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
Modernize the test driver #14344
Conversation
/botio test |
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.
It's really nice that you're doing this, but before I review it in detail there's one thing I fear is incorrect; please see the inline comment.
Just a word of warning: I actually tried that recently, but abandoned it for the time being since I ran into some trouble; please see #14287 (comment) |
…r.js` The wrapper functions in this case only really added indirection, so this commit simplifies the code a bit.
This is achieved by letting the `writeSVG` function return a promise so we don't need callback passing anymore.
62b9ca0
to
e64b4f1
Compare
This is done automatically with the `gulp lint --fix` command with the only exception of the `annotationLayerContext` variable.
e64b4f1
to
c686b16
Compare
c686b16
to
f3e353a
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.
r=me, with one final comment addressed (everywhere that it applies); thanks a lot for doing this!
I'd suggest running the tests maybe a couple of times, to ensure that there's no new intermittent failures (since the usage of async
perhaps affect timings ever so slightly).
This refactoring ensures that we can get rid of the closures and encapsulate the logic in a nicer way with e.g., getters for the style promises.
Now that the rasterization logic is encapsulated in a class, we can easily move the container creation into a separate static method.
f3e353a
to
911a9d3
Compare
/botio test |
From: Bot.io (Linux m4)ReceivedCommand cmd_test from @timvandermeij received. Current queue size: 0 Live output at: http://54.241.84.105:8877/d257169e1370e0e/output.txt |
From: Bot.io (Windows)ReceivedCommand cmd_test from @timvandermeij received. Current queue size: 0 Live output at: http://54.193.163.58:8877/3c60319b743fe02/output.txt |
From: Bot.io (Linux m4)FailedFull output at http://54.241.84.105:8877/d257169e1370e0e/output.txt Total script time: 21.19 mins
Image differences available at: http://54.241.84.105:8877/d257169e1370e0e/reftest-analyzer.html#web=eq.log |
From: Bot.io (Windows)FailedFull output at http://54.193.163.58:8877/3c60319b743fe02/output.txt Total script time: 42.02 mins
Image differences available at: http://54.193.163.58:8877/3c60319b743fe02/reftest-analyzer.html#web=eq.log |
/botio browsertest |
From: Bot.io (Windows)ReceivedCommand cmd_browsertest from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.193.163.58:8877/b9f9d44263dadc4/output.txt |
From: Bot.io (Linux m4)ReceivedCommand cmd_browsertest from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.241.84.105:8877/635bfee40cd6d1e/output.txt |
From: Bot.io (Linux m4)FailedFull output at http://54.241.84.105:8877/635bfee40cd6d1e/output.txt Total script time: 19.48 mins
Image differences available at: http://54.241.84.105:8877/635bfee40cd6d1e/reftest-analyzer.html#web=eq.log |
From: Bot.io (Windows)FailedFull output at http://54.193.163.58:8877/b9f9d44263dadc4/output.txt Total script time: 37.67 mins
Image differences available at: http://54.193.163.58:8877/b9f9d44263dadc4/reftest-analyzer.html#web=eq.log |
/botio browsertest |
From: Bot.io (Linux m4)ReceivedCommand cmd_browsertest from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.241.84.105:8877/d10b48e2ae41db2/output.txt |
From: Bot.io (Windows)ReceivedCommand cmd_browsertest from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.193.163.58:8877/3e138dd76ba1f10/output.txt |
From: Bot.io (Linux m4)FailedFull output at http://54.241.84.105:8877/d10b48e2ae41db2/output.txt Total script time: 19.49 mins
Image differences available at: http://54.241.84.105:8877/d10b48e2ae41db2/reftest-analyzer.html#web=eq.log |
From: Bot.io (Windows)FailedFull output at http://54.193.163.58:8877/3e138dd76ba1f10/output.txt Total script time: 37.34 mins
Image differences available at: http://54.193.163.58:8877/3e138dd76ba1f10/reftest-analyzer.html#web=eq.log |
The commit messages contain more information about the individual changes. The
?w=1
flag is most likely necessary for reviewing most commits.Initially I only tried to enable the
no-var
linting rule since our testing code is one of the final places where we exclude that rule, but I quickly found that the driver code could use further modernization. Hence this commit series, where each commit contains a separate refactoring step. Note that there is most likely more opportunity for improvement here, for instance using template strings more often and getting rid of XHR, but I deliberately left that for a follow-up since this series is already quite a big.This PR makes the driver code 103 lines shorter and, in my opinion at least, easier to understand and work with.