mirror of
https://github.com/servo/servo
synced 2026-04-28 10:27:40 +02:00
Remove [PrimaryGlobal]
This commit is contained in:
@@ -80,100 +80,6 @@ def WebIDLTest(parser, harness):
|
||||
|
||||
harness.ok(threw, "Should not allow indirect cycles in interface inheritance chains")
|
||||
|
||||
parser = parser.reset()
|
||||
threw = False
|
||||
try:
|
||||
parser.parse("""
|
||||
interface A {};
|
||||
interface B {};
|
||||
A implements B;
|
||||
B implements A;
|
||||
""")
|
||||
results = parser.finish()
|
||||
except:
|
||||
threw = True
|
||||
|
||||
harness.ok(threw, "Should not allow cycles via implements")
|
||||
|
||||
parser = parser.reset()
|
||||
threw = False
|
||||
try:
|
||||
parser.parse("""
|
||||
interface A {};
|
||||
interface C {};
|
||||
interface B {};
|
||||
A implements C;
|
||||
C implements B;
|
||||
B implements A;
|
||||
""")
|
||||
results = parser.finish()
|
||||
except:
|
||||
threw = True
|
||||
|
||||
harness.ok(threw, "Should not allow indirect cycles via implements")
|
||||
|
||||
parser = parser.reset()
|
||||
threw = False
|
||||
try:
|
||||
parser.parse("""
|
||||
interface A : B {};
|
||||
interface B {};
|
||||
B implements A;
|
||||
""")
|
||||
results = parser.finish()
|
||||
except:
|
||||
threw = True
|
||||
|
||||
harness.ok(threw, "Should not allow inheriting from an interface that implements us")
|
||||
|
||||
parser = parser.reset()
|
||||
threw = False
|
||||
try:
|
||||
parser.parse("""
|
||||
interface A : B {};
|
||||
interface B {};
|
||||
interface C {};
|
||||
B implements C;
|
||||
C implements A;
|
||||
""")
|
||||
results = parser.finish()
|
||||
except:
|
||||
threw = True
|
||||
|
||||
harness.ok(threw, "Should not allow inheriting from an interface that indirectly implements us")
|
||||
|
||||
parser = parser.reset()
|
||||
threw = False
|
||||
try:
|
||||
parser.parse("""
|
||||
interface A : B {};
|
||||
interface B : C {};
|
||||
interface C {};
|
||||
C implements A;
|
||||
""")
|
||||
results = parser.finish()
|
||||
except:
|
||||
threw = True
|
||||
|
||||
harness.ok(threw, "Should not allow indirectly inheriting from an interface that implements us")
|
||||
|
||||
parser = parser.reset()
|
||||
threw = False
|
||||
try:
|
||||
parser.parse("""
|
||||
interface A : B {};
|
||||
interface B : C {};
|
||||
interface C {};
|
||||
interface D {};
|
||||
C implements D;
|
||||
D implements A;
|
||||
""")
|
||||
results = parser.finish()
|
||||
except:
|
||||
threw = True
|
||||
|
||||
harness.ok(threw, "Should not allow indirectly inheriting from an interface that indirectly implements us")
|
||||
|
||||
parser = parser.reset()
|
||||
threw = False
|
||||
try:
|
||||
@@ -377,7 +283,7 @@ def WebIDLTest(parser, harness):
|
||||
|
||||
parser = parser.reset()
|
||||
parser.parse("""
|
||||
[Global] interface Window {};
|
||||
[Global, Exposed=Window] interface Window {};
|
||||
[Exposed=Window, LegacyWindowAlias=A]
|
||||
interface B {};
|
||||
[Exposed=Window, LegacyWindowAlias=(C, D)]
|
||||
@@ -419,7 +325,8 @@ def WebIDLTest(parser, harness):
|
||||
threw = False
|
||||
try:
|
||||
parser.parse("""
|
||||
[Global] interface Window {};
|
||||
[Global, Exposed=Window] interface Window {};
|
||||
[Exposed=Window]
|
||||
interface A {};
|
||||
[Exposed=Window, LegacyWindowAlias=A]
|
||||
interface B {};
|
||||
@@ -434,9 +341,10 @@ def WebIDLTest(parser, harness):
|
||||
threw = False
|
||||
try:
|
||||
parser.parse("""
|
||||
[Global] interface Window {};
|
||||
[Global, Exposed=Window] interface Window {};
|
||||
[Exposed=Window, LegacyWindowAlias=A]
|
||||
interface B {};
|
||||
[Exposed=Window]
|
||||
interface A {};
|
||||
""")
|
||||
results = parser.finish()
|
||||
@@ -449,7 +357,7 @@ def WebIDLTest(parser, harness):
|
||||
threw = False
|
||||
try:
|
||||
parser.parse("""
|
||||
[Global] interface Window {};
|
||||
[Global, Exposed=Window] interface Window {};
|
||||
[Exposed=Window, LegacyWindowAlias=A]
|
||||
interface B {};
|
||||
[Exposed=Window, LegacyWindowAlias=A]
|
||||
|
||||
Reference in New Issue
Block a user