aboutsummaryrefslogtreecommitdiffstats
path: root/third_party/WebIDL/tests/test_replaceable.py
diff options
context:
space:
mode:
authorNgo Iok Ui (Wu Yu Wei) <yuweiwu@pm.me>2024-06-15 13:22:42 +0900
committerGitHub <noreply@github.com>2024-06-15 04:22:42 +0000
commit8eed3b442b214f678b80dbcc7dca07eeaa1e26ff (patch)
treef8a232e86616e8e5fd234e7bbb32bed4ff7077f2 /third_party/WebIDL/tests/test_replaceable.py
parent19067366df28c9131dcbc436bc96a27e64e0a194 (diff)
downloadservo-8eed3b442b214f678b80dbcc7dca07eeaa1e26ff.tar.gz
servo-8eed3b442b214f678b80dbcc7dca07eeaa1e26ff.zip
Update WebIDL.py (#32495)
* Update WebIDL.py * Update WebIDL.py * Add builtin-array.patch * Fix CodegenRust.py and Configuration.py * Fix missing downcasts * mach fmt * Update check and comment to explain why we need this check * Update Global of DissimilarOriginWindow.webidl
Diffstat (limited to 'third_party/WebIDL/tests/test_replaceable.py')
-rw-r--r--third_party/WebIDL/tests/test_replaceable.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/third_party/WebIDL/tests/test_replaceable.py b/third_party/WebIDL/tests/test_replaceable.py
index 06ea6a47239..3b0a6fea360 100644
--- a/third_party/WebIDL/tests/test_replaceable.py
+++ b/third_party/WebIDL/tests/test_replaceable.py
@@ -2,6 +2,8 @@
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+import WebIDL
+
def should_throw(parser, harness, message, code):
parser = parser.reset()
@@ -9,7 +11,7 @@ def should_throw(parser, harness, message, code):
try:
parser.parse(code)
parser.finish()
- except:
+ except WebIDL.WebIDLError:
threw = True
harness.ok(threw, "Should have thrown: %s" % message)