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

Paint worklets: Add pref for blocking sleep to be enabled for wpt tests #19630

Merged
merged 1 commit into from Dec 22, 2017
Merged
Changes from all commits
Commits
File filter...
Filter file types
Jump to…
Jump to file
Failed to load files.

Always

Just for now

"reftest"
],
"mozilla/worklets/test_paint_worklet_timeout.js": [
"83cdbd59c905de898b72ba47d3ae10bb95d76301",
"3e4ff24fc85ad2956b741ff1785cecfb9641d792",
"support"
],
"mozilla/worklets/test_paint_worklet_timeout_ref.html": [
@@ -1 +1 @@
prefs: [dom.worklet.enabled:true]
prefs: [dom.worklet.enabled:true,dom.worklet.blockingsleep.enabled:true]
@@ -1,7 +1,12 @@
registerPaint("testgreen", class {
paint(ctx, size) {
try {
sleep(30); // too long for a paintworklet to init
} catch (e) {
console.log("Problem sleeping: " + e);
}
// should fail if control reaches here before timeout
ctx.fillStyle = 'green';
ctx.fillRect(0, 0, size.width, size.height);
sleep(30); // too long for a paintworklet to init
}
});
ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.