blob: 706a8c5e93d629329d03091fdc0c1d53a42945f9 [file] [log] [blame]
<!DOCTYPE html>
<!-- DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. -->
<title>OffscreenCanvas test: 2d.getcontext.exists</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/html/canvas/resources/canvas-tests.js"></script>
<h1>2d.getcontext.exists</h1>
<p class="desc">The 2D context is implemented</p>
<script>
var t = async_test("The 2D context is implemented");
var t_pass = t.done.bind(t);
var t_fail = t.step_func(function(reason) {
throw reason;
});
t.step(function() {
var offscreenCanvas = new OffscreenCanvas(100, 50);
var ctx = offscreenCanvas.getContext('2d');
var offscreenCanvas2 = new OffscreenCanvas(100, 50);
_assertDifferent(offscreenCanvas2.getContext('2d'), null, "offscreenCanvas2.getContext('2d')", "null");
t.done();
});
</script>