LEFT | RIGHT |
1 "use strict"; | 1 "use strict"; |
2 | 2 |
| 3 (function() |
3 { | 4 { |
4 const {Filter, ElemHideFilter} = require("filterClasses"); | 5 const {Filter, ElemHideFilter} = require("filterClasses"); |
5 const {escapeCSS, quoteCSS} = require("filterComposer"); | 6 const {escapeCSS, quoteCSS} = require("filterComposer"); |
6 | 7 |
7 module("CSS escaping"); | 8 module("CSS escaping"); |
8 | 9 |
9 test("CSS escaping", () => | 10 test("CSS escaping", () => |
10 { | 11 { |
11 function testSelector(opts) | 12 function testSelector(opts) |
12 { | 13 { |
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
91 testEscape("x" + chr); | 92 testEscape("x" + chr); |
92 | 93 |
93 // Leading dashes must be escaped, when followed by certain characters. | 94 // Leading dashes must be escaped, when followed by certain characters. |
94 testEscape("-" + chr); | 95 testEscape("-" + chr); |
95 } | 96 } |
96 | 97 |
97 // Test some non-ASCII characters. However, those shouldn't | 98 // Test some non-ASCII characters. However, those shouldn't |
98 // require escaping. | 99 // require escaping. |
99 testEscape("\uD83D\uDE3B\u2665\u00E4"); | 100 testEscape("\uD83D\uDE3B\u2665\u00E4"); |
100 }); | 101 }); |
101 } | 102 }()); |
LEFT | RIGHT |