mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Update web-platform-tests to revision c792ea26624bde49b72afce348de07ab72fb9ad7
This commit is contained in:
parent
e051c5880e
commit
ca45711d07
178 changed files with 2163 additions and 1807 deletions
|
@ -14,22 +14,18 @@ from .serve import ConfigBuilder
|
|||
def test_make_hosts_file_nix():
|
||||
with ConfigBuilder(ports={"http": [8000]},
|
||||
browser_host="foo.bar",
|
||||
alternate_hosts={"alt": "foo2.bar"}) as c:
|
||||
alternate_hosts={"alt": "foo2.bar"},
|
||||
subdomains={"a", "b"},
|
||||
not_subdomains={"x, y"}) as c:
|
||||
hosts = serve.make_hosts_file(c, "192.168.42.42")
|
||||
lines = hosts.split("\n")
|
||||
assert set(lines) == {"",
|
||||
"192.168.42.42\tfoo.bar",
|
||||
"192.168.42.42\tfoo2.bar",
|
||||
"192.168.42.42\twww.foo.bar",
|
||||
"192.168.42.42\twww.foo2.bar",
|
||||
"192.168.42.42\twww1.foo.bar",
|
||||
"192.168.42.42\twww1.foo2.bar",
|
||||
"192.168.42.42\twww2.foo.bar",
|
||||
"192.168.42.42\twww2.foo2.bar",
|
||||
"192.168.42.42\txn--lve-6lad.foo.bar",
|
||||
"192.168.42.42\txn--lve-6lad.foo2.bar",
|
||||
"192.168.42.42\txn--n8j6ds53lwwkrqhv28a.foo.bar",
|
||||
"192.168.42.42\txn--n8j6ds53lwwkrqhv28a.foo2.bar"}
|
||||
"192.168.42.42\ta.foo.bar",
|
||||
"192.168.42.42\ta.foo2.bar",
|
||||
"192.168.42.42\tb.foo.bar",
|
||||
"192.168.42.42\tb.foo2.bar"}
|
||||
assert lines[-1] == ""
|
||||
|
||||
@pytest.mark.skipif(platform.uname()[0] != "Windows",
|
||||
|
@ -37,24 +33,22 @@ def test_make_hosts_file_nix():
|
|||
def test_make_hosts_file_windows():
|
||||
with ConfigBuilder(ports={"http": [8000]},
|
||||
browser_host="foo.bar",
|
||||
alternate_hosts={"alt": "foo2.bar"}) as c:
|
||||
alternate_hosts={"alt": "foo2.bar"},
|
||||
subdomains={"a", "b"},
|
||||
not_subdomains={"x, y"}) as c:
|
||||
hosts = serve.make_hosts_file(c, "192.168.42.42")
|
||||
lines = hosts.split("\n")
|
||||
assert set(lines) == {"",
|
||||
"0.0.0.0\tnonexistent.foo.bar",
|
||||
"0.0.0.0\tnonexistent.foo2.bar",
|
||||
"0.0.0.0\tx.foo.bar",
|
||||
"0.0.0.0\tx.foo2.bar",
|
||||
"0.0.0.0\ty.foo.bar",
|
||||
"0.0.0.0\ty.foo2.bar",
|
||||
"192.168.42.42\tfoo.bar",
|
||||
"192.168.42.42\tfoo2.bar",
|
||||
"192.168.42.42\twww.foo.bar",
|
||||
"192.168.42.42\twww.foo2.bar",
|
||||
"192.168.42.42\twww1.foo.bar",
|
||||
"192.168.42.42\twww1.foo2.bar",
|
||||
"192.168.42.42\twww2.foo.bar",
|
||||
"192.168.42.42\twww2.foo2.bar",
|
||||
"192.168.42.42\txn--lve-6lad.foo.bar",
|
||||
"192.168.42.42\txn--lve-6lad.foo2.bar",
|
||||
"192.168.42.42\txn--n8j6ds53lwwkrqhv28a.foo.bar",
|
||||
"192.168.42.42\txn--n8j6ds53lwwkrqhv28a.foo2.bar"}
|
||||
"192.168.42.42\ta.foo.bar",
|
||||
"192.168.42.42\ta.foo2.bar",
|
||||
"192.168.42.42\tb.foo.bar",
|
||||
"192.168.42.42\tb.foo2.bar"}
|
||||
assert lines[-1] == ""
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue