Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(341)

Unified Diff: third_party/WebKit/LayoutTests/external/wpt/web-animations/interfaces/KeyframeEffect/constructor.html

Issue 2704543002: Import wpt@3bd204d7e86fd81e98e63f4ce59b95d98bad1c54 (Closed)
Patch Set: Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/external/wpt/web-animations/interfaces/KeyframeEffect/constructor.html
diff --git a/third_party/WebKit/LayoutTests/external/wpt/web-animations/interfaces/KeyframeEffect/constructor.html b/third_party/WebKit/LayoutTests/external/wpt/web-animations/interfaces/KeyframeEffect/constructor.html
index f7c619950138793d1954ae10df51710fe52482bc..6be0c7872a64e440ec05db1fe8df97d9560730fb 100644
--- a/third_party/WebKit/LayoutTests/external/wpt/web-animations/interfaces/KeyframeEffect/constructor.html
+++ b/third_party/WebKit/LayoutTests/external/wpt/web-animations/interfaces/KeyframeEffect/constructor.html
@@ -5,6 +5,7 @@
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="../../testcommon.js"></script>
+<script src="../../resources/easing-tests.js"></script>
<script src="../../resources/keyframe-utils.js"></script>
<body>
<div id="log"></div>
@@ -66,7 +67,25 @@ test(function(t) {
"resulting easing for '" + easing + "'");
});
}, "easing values are parsed correctly when passed to the " +
- "KeyframeEffectReadOnly constructor in KeyframeTimingOptions");
+ "KeyframeEffectReadOnly constructor in KeyframeEffectOptions");
+
+test(function(t) {
+ gInvalidEasings.forEach(invalidEasing => {
+ assert_throws(new TypeError, () => {
+ new KeyframeEffectReadOnly(target, { easing: invalidEasing });
+ }, `TypeError is thrown for easing '${invalidEasing}'`);
+ });
+}, 'invalid easing values are correctly rejected when passed to the ' +
+ 'KeyframeEffectReadOnly constructor in regular keyframes');
+
+test(function(t) {
+ gInvalidEasings.forEach(invalidEasing => {
+ assert_throws(new TypeError, () => {
+ new KeyframeEffectReadOnly(target, null, { easing: invalidEasing });
+ }, `TypeError is thrown for easing '${invalidEasing}'`);
+ });
+}, 'invalid easing values are correctly rejected when passed to the ' +
+ 'KeyframeEffectReadOnly constructor in KeyframeEffectOptions');
test(function(t) {
var getKeyframe = function(composite) {

Powered by Google App Engine
This is Rietveld 408576698