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

Unified Diff: LayoutTests/media/media-controller-playback.html

Issue 217053009: Validate finiteness of HTMLMediaElement properties. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add LayoutTests. Created 6 years, 9 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/media/media-controller-playback.html
diff --git a/LayoutTests/media/media-controller-playback.html b/LayoutTests/media/media-controller-playback.html
index 10db0a71e5799c68f539cba9aea2ddc82f1a8198..cc765d6c0b2ff98a2cbd361daa9771facd79e91b 100644
--- a/LayoutTests/media/media-controller-playback.html
+++ b/LayoutTests/media/media-controller-playback.html
@@ -22,6 +22,11 @@
function canplaythrough() {
consoleWrite("EVENT(canplaythrough)");
controller.removeEventListener('canplaythrough', canplaythrough, true);
+
+ testException("controller.currentTime = -Infinity", "TypeError: Failed to set the 'currentTime' property on 'MediaController': The value provided is infinite.");
+ testException("controller.currentTime = Infinity", "TypeError: Failed to set the 'currentTime' property on 'MediaController': The value provided is infinite.");
+ testException("controller.currentTime = NaN", "TypeError: Failed to set the 'currentTime' property on 'MediaController': The value provided is not a number.");
+
controller.addEventListener('playing', playing, true);
run('controller.play()');
}

Powered by Google App Engine
This is Rietveld 408576698