https://github.com/web-platform-tests/wpt
Raw File
Tip revision: 359eccb6387fbcddabd822041f03649c61215c4e authored by Benjamin C. Wiley Sittler on 12 January 2018, 19:56:25 UTC
Async Cookies API: additional getAll coverage for unprefixed cookies
Tip revision: 359eccb
2d.path.arc.end.html
<!DOCTYPE html>
<!-- DO NOT EDIT! This test has been generated by tools/gentest.py. -->
<title>OffscreenCanvas test: 2d.path.arc.end</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/common/canvas-tests.js"></script>

<h1>2d.path.arc.end</h1>
<p class="desc">arc() adds the end point of the arc to the subpath</p>


<script>
var t = async_test("arc() adds the end point of the arc to the subpath");
t.step(function() {

var offscreenCanvas = new OffscreenCanvas(100, 50);
var ctx = offscreenCanvas.getContext('2d');

ctx.fillStyle = '#f00';
ctx.fillRect(0, 0, 100, 50);
ctx.lineWidth = 50;
ctx.strokeStyle = '#0f0';
ctx.beginPath();
ctx.moveTo(-100, 0);
ctx.arc(-100, 0, 25, -Math.PI/2, Math.PI/2, true);
ctx.lineTo(100, 25);
ctx.stroke();
_assertPixel(offscreenCanvas, 50,25, 0,255,0,255, "50,25", "0,255,0,255");

t.done();

});
</script>
back to top