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

Conversation

@yati-sagade
Copy link
Contributor

yati-sagade commented Dec 22, 2017

In aa48a2c I added a timeout for paint
worklet threads. However, the test was broken. The blocking sleep
function that was implemented as part of that commit was guarded behind
the dom.worklet.blockingsleep.enabled pref, and while I ran the
wpt-tests with that pref enabled, the test runner for sure did not.
I tried running the test without the pref enabled, and the tests still
pass. This is because even the reference in that reftest is that of
a broken image background, and both the paintworklet thread timing out
and sleep() not being in scope would render the same thing: a broken
image, which compares equal to the reference.

This patch makes sure that now the pref is enabled for wpt worklet
tests, and that such we can distinguish an actual timeout (test pass)
from an unexpected situation (when we should fail the test).


  • ./mach build -d does not report any errors
  • ./mach test-tidy does not report any errors
  • These changes fix #__ (github issue number if applicable). (not applicable)
  • [] There are tests for these changes OR
  • These changes do not require tests because this patch fixes a broken test.

This change is Reviewable

@highfive
Copy link

highfive commented Dec 22, 2017

Thanks for the pull request, and welcome! The Servo team is excited to review your changes, and you should hear from @pcwalton (or someone else) soon.

In aa48a2c I added a timeout for paint
worklet threads. However, the test was broken. The blocking sleep
function that was implemented as part of that commit was guarded behind
the `dom.worklet.blockingsleep.enabled` pref, and while I ran the
wpt-tests with that pref enabled, the test runner for sure did not.
I tried running the test _without_ the pref enabled, and the tests still
pass. This is because even the reference in that reftest is that of
a broken image background, and *both* the paintworklet thread timing out
and `sleep()` not being in scope would render the same thing: a broken
image, which compares equal to the reference.

This patch makes sure that now the pref is enabled for wpt worklet
tests, and that such we can distinguish an actual timeout (test pass)
from an unexpected situation (when we should fail the test).
@yati-sagade yati-sagade force-pushed the yati-sagade:master branch from 9791bf8 to 5a53cfd Dec 22, 2017
@jdm
Copy link
Member

jdm commented Dec 22, 2017

@bors-servo: r+
Thanks for fixing that!

@bors-servo
Copy link
Contributor

bors-servo commented Dec 22, 2017

📌 Commit 5a53cfd has been approved by jdm

@highfive highfive assigned jdm and unassigned pcwalton Dec 22, 2017
@bors-servo
Copy link
Contributor

bors-servo commented Dec 22, 2017

Testing commit 5a53cfd with merge bcdb82b...

bors-servo added a commit that referenced this pull request Dec 22, 2017
Paint worklets: Add pref for blocking sleep to be enabled for wpt tests

In aa48a2c I added a timeout for paint
worklet threads. However, the test was broken. The blocking sleep
function that was implemented as part of that commit was guarded behind
the `dom.worklet.blockingsleep.enabled` pref, and while I ran the
wpt-tests with that pref enabled, the test runner for sure did not.
I tried running the test _without_ the pref enabled, and the tests still
pass. This is because even the reference in that reftest is that of
a broken image background, and *both* the paintworklet thread timing out
and `sleep()` not being in scope would render the same thing: a broken
image, which compares equal to the reference.

This patch makes sure that now the pref is enabled for wpt worklet
tests, and that such we can distinguish an actual timeout (test pass)
from an unexpected situation (when we should fail the test).

<!-- Please describe your changes on the following line: -->

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #__ (github issue number if applicable). (*not applicable*)

<!-- Either: -->
- [] There are tests for these changes OR
- [X] These changes do not require tests because this patch fixes a broken test.

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/19630)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

bors-servo commented Dec 22, 2017

💔 Test failed - mac-dev-unit

@jdm
Copy link
Member

jdm commented Dec 22, 2017

@bors-servo
Copy link
Contributor

bors-servo commented Dec 22, 2017

@bors-servo
Copy link
Contributor

bors-servo commented Dec 22, 2017

💔 Test failed - linux-rel-css

@jdm
Copy link
Member

jdm commented Dec 22, 2017

tests/wpt/mozilla/tests/mozilla/css-paint-api/paint2d-image.html appears to be failing.

@jdm
Copy link
Member

jdm commented Dec 22, 2017

@bors-servo
Copy link
Contributor

bors-servo commented Dec 22, 2017

@bors-servo
Copy link
Contributor

bors-servo commented Dec 22, 2017

@bors-servo bors-servo merged commit 5a53cfd into servo:master Dec 22, 2017
3 checks passed
3 checks passed
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
homu Test successful
Details
@yati-sagade
Copy link
Contributor Author

yati-sagade commented Dec 22, 2017

phew, thanks @jdm for the kicks!

@tigercosmos
Copy link
Collaborator

tigercosmos commented Dec 25, 2017

Hi @yati-sagade,
just mention that your commit's config.email doesn't match what your github is, which means you will not calculate as a contributor.

@yati-sagade
Copy link
Contributor Author

yati-sagade commented Dec 25, 2017

Hey, thanks for pointing out @tigercosmos. I did not know one can have multiple emails on a github account (added).

@tigercosmos
Copy link
Collaborator

tigercosmos commented Dec 25, 2017

nice!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

6 participants
You can’t perform that action at this time.