OLD | NEW |
1 // Requires custom-filter-parsing-common.js. | 1 // Requires custom-filter-parsing-common.js. |
2 | 2 |
3 description("Test at-rule parsing for @-webkit-filter."); | 3 description("Test at-rule parsing for @-webkit-filter."); |
4 | 4 |
5 // These have to be global for the test helpers to see them. | 5 // These have to be global for the test helpers to see them. |
6 var cssRule, insertRuleException; | 6 var cssRule, insertRuleException; |
7 | 7 |
8 function testInvalidFilterAtRule(description, rule) | 8 function testInvalidFilterAtRule(description, rule) |
9 { | 9 { |
10 debug("\n" + description + "\n" + rule); | 10 debug("\n" + description + "\n" + rule); |
(...skipping 12 matching lines...) Expand all Loading... |
23 testInvalidFilterAtRule("Unprefixed rule.", "@filter my-filter { }"); | 23 testInvalidFilterAtRule("Unprefixed rule.", "@filter my-filter { }"); |
24 | 24 |
25 heading("Filter name tests."); | 25 heading("Filter name tests."); |
26 testInvalidFilterAtRule("Missing filter name identifier.", "@-webkit-filter { }"
); | 26 testInvalidFilterAtRule("Missing filter name identifier.", "@-webkit-filter { }"
); |
27 testInvalidFilterAtRule("Filter name as string.", "@-webkit-filter 'my-filter' {
}"); | 27 testInvalidFilterAtRule("Filter name as string.", "@-webkit-filter 'my-filter' {
}"); |
28 testInvalidFilterAtRule("Filter name as number.", "@-webkit-filter 123 { }"); | 28 testInvalidFilterAtRule("Filter name as number.", "@-webkit-filter 123 { }"); |
29 | 29 |
30 heading("Filter at-rule body tests."); | 30 heading("Filter at-rule body tests."); |
31 testInvalidFilterAtRule("Missing rule body.", "@-webkit-filter my-filter"); | 31 testInvalidFilterAtRule("Missing rule body.", "@-webkit-filter my-filter"); |
32 testInvalidFilterAtRule("Missing opening brace.", "@-webkit-filter my-filter }")
; | 32 testInvalidFilterAtRule("Missing opening brace.", "@-webkit-filter my-filter }")
; |
33 testInvalidFilterAtRule("Missing closing brace.", "@-webkit-filter my-filter {")
; | |
OLD | NEW |