summaryrefslogtreecommitdiff
path: root/cli/tests
diff options
context:
space:
mode:
authorYacine Hmito <yacinehmito@users.noreply.github.com>2021-01-09 07:27:46 +0100
committerGitHub <noreply@github.com>2021-01-09 07:27:46 +0100
commit96372097657685b5655bba95ce5a329364a9301b (patch)
tree7f0fda60e9cdad0c4a4862e86f8c1e45e3f92f82 /cli/tests
parentf3ead9c6a7184d2b592f018795f73d34399a9c83 (diff)
fix(web): implement DOMException#code (#9015)
Co-authored-by: Luca Casonato <lucacasonato@yahoo.com>
Diffstat (limited to 'cli/tests')
-rw-r--r--cli/tests/unit/dom_exception_test.ts9
-rw-r--r--cli/tests/wpt.jsonc9
2 files changed, 10 insertions, 8 deletions
diff --git a/cli/tests/unit/dom_exception_test.ts b/cli/tests/unit/dom_exception_test.ts
index a93cbfebe..4c9e96de6 100644
--- a/cli/tests/unit/dom_exception_test.ts
+++ b/cli/tests/unit/dom_exception_test.ts
@@ -6,4 +6,13 @@ unitTest(function testDomError() {
assert(de);
assertEquals(de.message, "foo");
assertEquals(de.name, "bar");
+ assertEquals(de.code, 0);
+});
+
+unitTest(function testKnownDomException() {
+ const de = new DOMException("foo", "SyntaxError");
+ assert(de);
+ assertEquals(de.message, "foo");
+ assertEquals(de.name, "SyntaxError");
+ assertEquals(de.code, 12);
});
diff --git a/cli/tests/wpt.jsonc b/cli/tests/wpt.jsonc
index 3099d3b48..d43aa9ce6 100644
--- a/cli/tests/wpt.jsonc
+++ b/cli/tests/wpt.jsonc
@@ -170,14 +170,7 @@
]
},
"measure-l3",
- {
- "name": "structured-serialize-detail",
- "expectFail": [
- // TODO(lucacasonato): re-enable when we use real structured clone.
- "Mark: Throw an exception when the detail property cannot be structured-serialized.",
- "Measure: Throw an exception when the detail property cannot be structured-serialized."
- ]
- },
+ "structured-serialize-detail",
"user_timing_exists"
]
}