mirror of
https://github.com/servo/servo
synced 2026-04-28 10:27:40 +02:00
update to latest tests
This commit is contained in:
committed by
Prabhjyot Singh Sodhi
parent
175b3c2d27
commit
da40818f25
@@ -2,11 +2,11 @@ import WebIDL
|
||||
|
||||
def WebIDLTest(parser, harness):
|
||||
parser.parse("""
|
||||
callback Function = any(any... arguments);
|
||||
[TreatNonCallableAsNull] callback Function = any(any... arguments);
|
||||
|
||||
interface TestTreatNonCallableAsNull1 {
|
||||
[TreatNonCallableAsNull] attribute Function? onfoo;
|
||||
attribute Function? onbar;
|
||||
attribute Function? onfoo;
|
||||
attribute Function onbar;
|
||||
};
|
||||
""")
|
||||
|
||||
@@ -54,3 +54,18 @@ def WebIDLTest(parser, harness):
|
||||
threw = True
|
||||
|
||||
harness.ok(threw, "Should have thrown.")
|
||||
|
||||
parser = parser.reset()
|
||||
|
||||
threw = False
|
||||
try:
|
||||
parser.parse("""
|
||||
[TreatNonCallableAsNull, TreatNonObjectAsNull]
|
||||
callback Function = any(any... arguments);
|
||||
""")
|
||||
|
||||
results = parser.finish()
|
||||
except:
|
||||
threw = True
|
||||
|
||||
harness.ok(threw, "Should have thrown.")
|
||||
|
||||
Reference in New Issue
Block a user