1
0
Fork 0
firefox/dom/webgpu/tests/mochitest/test_adapter_enabled.html
Daniel Baumann 5e9a113729
Adding upstream version 140.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
2025-06-25 09:37:52 +02:00

26 lines
686 B
HTML

<!doctype html>
<html>
<head>
<meta charset="utf-8" />
<script src="/tests/SimpleTest/SimpleTest.js"></script>
<link rel="stylesheet" href="/tests/SimpleTest/test.css" />
</head>
<body>
<script>
const func = async function () {
var gotException = false;
try {
await navigator.gpu.requestAdapter();
} catch (ex) {
gotException = true;
}
ok(!gotException, "requesting an adapter should not throw");
};
SimpleTest.waitForExplicitFinish();
func()
.catch(e => ok(false, "Unhandled exception " + e))
.finally(() => SimpleTest.finish());
</script>
</body>
</html>