mirror of
https://github.com/servo/servo.git
synced 2025-08-19 04:15:33 +01:00
Update web-platform-tests to revision 3137d1d2d7757366a69f8a449b458b5057e0e81e
This commit is contained in:
parent
81ca858678
commit
d6ba94ca28
2339 changed files with 89274 additions and 9328 deletions
|
@ -0,0 +1,30 @@
|
|||
<!DOCTYPE html>
|
||||
<!-- DO NOT EDIT! This test has been generated by tools/gentest.py. -->
|
||||
<title>OffscreenCanvas test: 2d.composite.transparent.source-out</title>
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/common/canvas-tests.js"></script>
|
||||
|
||||
<h1>2d.composite.transparent.source-out</h1>
|
||||
<p class="desc"></p>
|
||||
|
||||
|
||||
<script>
|
||||
var t = async_test("");
|
||||
t.step(function() {
|
||||
|
||||
var offscreenCanvas = new OffscreenCanvas(100, 50);
|
||||
var ctx = offscreenCanvas.getContext('2d');
|
||||
|
||||
|
||||
ctx.fillStyle = 'rgba(0, 255, 0, 0.5)';
|
||||
ctx.fillRect(0, 0, 100, 50);
|
||||
ctx.globalCompositeOperation = 'source-out';
|
||||
ctx.fillStyle = 'rgba(0, 0, 255, 0.75)';
|
||||
ctx.fillRect(0, 0, 100, 50);
|
||||
_assertPixelApprox(offscreenCanvas, 50,25, 0,0,255,96, "50,25", "0,0,255,96", 5);
|
||||
|
||||
t.done();
|
||||
|
||||
});
|
||||
</script>
|
Loading…
Add table
Add a link
Reference in a new issue