Skip to content

Commit

Permalink
Make test work in strict mode.
Browse files Browse the repository at this point in the history
  • Loading branch information
rictic committed Aug 3, 2017
1 parent 674d468 commit 328ce59
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions test/unit/dom-repeat.html
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@ <h4>x-repeat-chunked</h4>

<script>
(function() {
'use strict';
/* global limited inDocumentRepeater inDocumentContainer inDocumentContainerOrig stamped:true chunked nonUpgrade*/

/*
Expand Down Expand Up @@ -3607,7 +3608,7 @@ <h4>x-repeat-chunked</h4>
test('increase limit above items.length', function() {
limited.$.repeater.__limit = 30;
limited.$.repeater.render();
stamped = limited.root.querySelectorAll('*:not(template):not(dom-repeat)');
var stamped = limited.root.querySelectorAll('*:not(template):not(dom-repeat)');
assert.equal(stamped.length, 20);
checkItemOrder(stamped);
});
Expand All @@ -3629,7 +3630,7 @@ <h4>x-repeat-chunked</h4>
test('negative limit', function() {
limited.$.repeater.__limit = -10;
limited.$.repeater.render();
stamped = limited.root.querySelectorAll('*:not(template):not(dom-repeat)');
var stamped = limited.root.querySelectorAll('*:not(template):not(dom-repeat)');
assert.equal(stamped.length, 0);
});

Expand Down Expand Up @@ -3675,7 +3676,7 @@ <h4>x-repeat-chunked</h4>
test('increase limit above items.length', function() {
limited.$.repeater.__limit = 30;
limited.$.repeater.render();
stamped = limited.root.querySelectorAll('*:not(template):not(dom-repeat)');
var stamped = limited.root.querySelectorAll('*:not(template):not(dom-repeat)');
assert.equal(stamped.length, 20);
checkItemOrder(stamped);
});
Expand All @@ -3697,7 +3698,7 @@ <h4>x-repeat-chunked</h4>
test('negative limit', function() {
limited.$.repeater.__limit = -10;
limited.$.repeater.render();
stamped = limited.root.querySelectorAll('*:not(template):not(dom-repeat)');
var stamped = limited.root.querySelectorAll('*:not(template):not(dom-repeat)');
assert.equal(stamped.length, 0);
});

Expand Down Expand Up @@ -3745,7 +3746,7 @@ <h4>x-repeat-chunked</h4>
test('increase limit above items.length', function() {
limited.$.repeater.__limit = 30;
limited.$.repeater.render();
stamped = limited.root.querySelectorAll('*:not(template):not(dom-repeat)');
var stamped = limited.root.querySelectorAll('*:not(template):not(dom-repeat)');
assert.equal(stamped.length, 10);
checkItemOrder(stamped);
});
Expand All @@ -3767,7 +3768,7 @@ <h4>x-repeat-chunked</h4>
test('negative limit', function() {
limited.$.repeater.__limit = -10;
limited.$.repeater.render();
stamped = limited.root.querySelectorAll('*:not(template):not(dom-repeat)');
var stamped = limited.root.querySelectorAll('*:not(template):not(dom-repeat)');
assert.equal(stamped.length, 0);
});

Expand Down Expand Up @@ -3817,7 +3818,7 @@ <h4>x-repeat-chunked</h4>
test('increase limit above items.length', function() {
limited.$.repeater.__limit = 30;
limited.$.repeater.render();
stamped = limited.root.querySelectorAll('*:not(template):not(dom-repeat)');
var stamped = limited.root.querySelectorAll('*:not(template):not(dom-repeat)');
assert.equal(stamped.length, 10);
checkItemOrder(stamped);
});
Expand All @@ -3839,7 +3840,7 @@ <h4>x-repeat-chunked</h4>
test('negative limit', function() {
limited.$.repeater.__limit = -10;
limited.$.repeater.render();
stamped = limited.root.querySelectorAll('*:not(template):not(dom-repeat)');
var stamped = limited.root.querySelectorAll('*:not(template):not(dom-repeat)');
assert.equal(stamped.length, 0);
});

Expand Down

0 comments on commit 328ce59

Please sign in to comment.