Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / url / invalid-urls-utf8.html
blob85cae779ae18c6729211bdf8906a1b2a31a745df
1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
2 <html>
3 <head>
4 <script src="../../resources/js-test.js"></script>
5 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
6 <script src="resources/utilities.js"></script>
7 <!-- Set the base so that the current URL does not affect the tests. -->
8 <base href="">
9 </head>
10 <body>
12 <script>
13 description("This ensure we do not mess up the bytes when an URL is partially parsed and is invalid.")
15 // Those are all invalid URLs. They should not be partially modified by the parser.
16 var testSet = [
17 // Empty Authority for a standard hierachical URL.
18 'http:///',
19 'https:///',
20 'ftp:///',
21 'gopher:///',
22 'ws:///',
23 'wss:///',
25 // Invalid Authority.
26 'foo://tête à tête@host/',
27 'foo://user:tête à tête@host/',
28 ' foo://<>@host/ ',
29 ' foo://user:<>@host/ ',
30 'foo://user:password@[xxxxx]/tête à tête/',
32 // The '?' is a path separator and make sure the hostname is not encoded in punicode. The hostname is an invalid IPV6 hostname.
33 'foo://user:password@[?tête à tête/',
34 'foo://user:password@[?tête à tête]/',
35 'foo://user:password@host:tête à tête/',
36 'foo://user:password@host:80tête à tête',
37 'foo://user:password@host:tête à tête/',
38 'foo://user:password@host:80tête à tête',
39 // The schemes "ws:", "ftp:", "http:", "https:", "gother:" take a shortcut during parsing so we test them separately.
40 'ws:/tête',
41 'ftp:/tête',
42 'http:/tête',
43 'https:/tête',
44 'gopher:/tête',
47 for (var i = 0; i < testSet.length; ++i) {
48 src = canonicalize(testSet[i]);
49 expected = testSet[i].trim();
50 shouldBe('src', 'expected');
53 successfullyParsed = true;
54 </script>
55 </body>
56 </html>