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

Unified Diff: LayoutTests/fast/events/constructors/webkit-animation-event-constructor.html

Issue 939623002: Add TypeChecking=Unrestricted to Web Animation APIs (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Drop AnimationAnimationPlayerTest.SetCurrentTimeUnrestrictedDouble Created 5 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: LayoutTests/fast/events/constructors/webkit-animation-event-constructor.html
diff --git a/LayoutTests/fast/events/constructors/webkit-animation-event-constructor.html b/LayoutTests/fast/events/constructors/webkit-animation-event-constructor.html
index a3d92a8242f4bfebc0ffeef46fe8629d4f95d82c..f5686a7bc1bfaefc5955f8f7ee59e18bc13cc2da 100644
--- a/LayoutTests/fast/events/constructors/webkit-animation-event-constructor.html
+++ b/LayoutTests/fast/events/constructors/webkit-animation-event-constructor.html
@@ -46,9 +46,9 @@ shouldBe("new WebKitAnimationEvent('eventType', { elapsedTime: 0 }).elapsedTime"
shouldBe("new WebKitAnimationEvent('eventType', { elapsedTime: 123.45 }).elapsedTime", "123.45");
shouldBe("new WebKitAnimationEvent('eventType', { elapsedTime: -123.45 }).elapsedTime", "-123.45");
shouldBe("new WebKitAnimationEvent('eventType', { elapsedTime: 18446744073709551615 }).elapsedTime", "18446744073709551615");
-shouldBe("new WebKitAnimationEvent('eventType', { elapsedTime: NaN }).elapsedTime", "NaN");
-shouldBe("new WebKitAnimationEvent('eventType', { elapsedTime: Infinity }).elapsedTime", "Infinity");
-shouldBe("new WebKitAnimationEvent('eventType', { elapsedTime: -Infinity }).elapsedTime", "-Infinity");
+shouldThrow("new WebKitAnimationEvent('eventType', { elapsedTime: NaN }).elapsedTime");
+shouldThrow("new WebKitAnimationEvent('eventType', { elapsedTime: Infinity }).elapsedTime");
+shouldThrow("new WebKitAnimationEvent('eventType', { elapsedTime: -Infinity }).elapsedTime");
// Non-numeric values.
shouldBe("new WebKitAnimationEvent('eventType', { elapsedTime: undefined }).elapsedTime", "0");
@@ -56,11 +56,11 @@ shouldBe("new WebKitAnimationEvent('eventType', { elapsedTime: null }).elapsedTi
shouldBe("new WebKitAnimationEvent('eventType', { elapsedTime: false }).elapsedTime", "0");
shouldBe("new WebKitAnimationEvent('eventType', { elapsedTime: true }).elapsedTime", "1");
shouldBe("new WebKitAnimationEvent('eventType', { elapsedTime: '' }).elapsedTime", "0");
-shouldBe("new WebKitAnimationEvent('eventType', { elapsedTime: 'doremi' }).elapsedTime", "NaN");
+shouldThrow("new WebKitAnimationEvent('eventType', { elapsedTime: 'doremi' }).elapsedTime");
shouldBe("new WebKitAnimationEvent('eventType', { elapsedTime: [] }).elapsedTime", "0");
shouldBe("new WebKitAnimationEvent('eventType', { elapsedTime: [123.45] }).elapsedTime", "123.45");
-shouldBe("new WebKitAnimationEvent('eventType', { elapsedTime: [123.45, 678.90] }).elapsedTime", "NaN");
-shouldBe("new WebKitAnimationEvent('eventType', { elapsedTime: {doremi: 123.45} }).elapsedTime", "NaN");
+shouldThrow("new WebKitAnimationEvent('eventType', { elapsedTime: [123.45, 678.90] }).elapsedTime");
+shouldThrow("new WebKitAnimationEvent('eventType', { elapsedTime: {doremi: 123.45} }).elapsedTime");
shouldBe("new WebKitAnimationEvent('eventType', { elapsedTime: {valueOf: function () { return 123.45 } } }).elapsedTime", "123.45");
// All initializers are passed.

Powered by Google App Engine
This is Rietveld 408576698