Bug 1415448 - Consistently use strict mode in web-platform-tests/web-animations; r?hiro
MozReview-Commit-ID: Gj4542CXvi9
--- a/testing/web-platform/tests/web-animations/animation-model/animation-types/property-types.js
+++ b/testing/web-platform/tests/web-animations/animation-model/animation-types/property-types.js
@@ -1,8 +1,10 @@
+'use strict';
+
const discreteType = {
testInterpolation: (property, setup, options) => {
options.forEach(keyframes => {
const [ from, to ] = keyframes;
test(t => {
const idlName = propertyToIDL(property);
const target = createTestElement(t, setup);
const animation = target.animate({ [idlName]: [from, to] },
--- a/testing/web-platform/tests/web-animations/animation-model/keyframe-effects/effect-value-context.html
+++ b/testing/web-platform/tests/web-animations/animation-model/keyframe-effects/effect-value-context.html
@@ -3,16 +3,17 @@
<title>Calculating computed keyframes: Property values that depend on their context (target element)</title>
<link rel="help" href="https://w3c.github.io/web-animations/#calculating-computed-keyframes">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="../../testcommon.js"></script>
<body>
<div id="log"></div>
<script>
+'use strict';
test(t => {
const div = createDiv(t);
div.style.fontSize = '10px';
const animation = div.animate([ { marginLeft: '10em' },
{ marginLeft: '20em' } ], 1000);
animation.currentTime = 500;
assert_equals(getComputedStyle(div).marginLeft, '150px',
--- a/testing/web-platform/tests/web-animations/resources/easing-tests.js
+++ b/testing/web-platform/tests/web-animations/resources/easing-tests.js
@@ -1,8 +1,10 @@
+'use strict';
+
const gEasingTests = [
{
desc: 'step-start function',
easing: 'step-start',
easingFunction: stepStart(1),
serialization: 'steps(1, start)'
},
{
--- a/testing/web-platform/tests/web-animations/resources/effect-tests.js
+++ b/testing/web-platform/tests/web-animations/resources/effect-tests.js
@@ -1,8 +1,10 @@
+'use strict';
+
// Common utility methods for testing animation effects
// Tests the |property| member of |animation's| target effect's computed timing
// at the various points indicated by |values|.
//
// |values| has the format:
//
// {