Index: test/elemHide.js |
=================================================================== |
--- a/test/elemHide.js |
+++ b/test/elemHide.js |
@@ -292,17 +292,19 @@ |
"html", "#foo", ".bar", "#foo .bar", "#foo > .bar", |
"#foo[data-bar='bar']" |
]), |
"html, #foo, .bar, #foo .bar, #foo > .bar, #foo[data-bar='bar'] " + |
"{display: none !important;}\n", |
"Style sheet creation should work" |
); |
- let selectors = new Array(50000).map((element, index) => ".s" + index); |
+ let selectors = new Array(50000); |
+ for (let index = 0; index < selectors.length; index++) |
+ selectors[index] = ".s" + index; |
test.equal((createStyleSheet(selectors).match(/\n/g) || []).length, |
Math.ceil(50000 / selectorGroupSize), |
"Style sheet should be split up into rules with at most " + |
selectorGroupSize + " selectors each"); |
test.done(); |
}; |