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

Unified Diff: third_party/WebKit/LayoutTests/media/audio-controls-captions.html

Issue 2004963003: Convert audio-controls* and audio-delete* tests to testharness.js (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 years, 7 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
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/media/audio-controls-captions-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/media/audio-controls-captions.html
diff --git a/third_party/WebKit/LayoutTests/media/audio-controls-captions.html b/third_party/WebKit/LayoutTests/media/audio-controls-captions.html
index a3f5c874edb5bccae4ed2639a9abe0466c3ba6fd..cdfd5e3d3689813ebea6ca7edf6be043e95f716e 100644
--- a/third_party/WebKit/LayoutTests/media/audio-controls-captions.html
+++ b/third_party/WebKit/LayoutTests/media/audio-controls-captions.html
@@ -1,27 +1,18 @@
<!DOCTYPE html>
-<html>
-<head>
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
- <title>Test closed caption button visbility.</title>
- <script src=media-file.js></script>
- <script src=media-controls.js></script>
- <!-- TODO(foolip): Convert test to testharness.js. crbug.com/588956
- (Please avoid writing new tests using video-test.js) -->
- <script src=video-test.js></script>
-</head>
-<body>
- <p>Tests that the closed captions button is not visible.</p>
- <audio controls>
- <track src="track/captions-webvtt/captions-fast.vtt">
- </audio>
- <script>
- findMediaElement();
- audio.src = findMediaFile('audio', 'content/test');
- audio.addEventListener('loadedmetadata', function()
- {
- testClosedCaptionsButtonVisibility(false);
- endTest();
- });
- </script>
-</body>
-</html>
+<title>Tests that the closed captions button is not visible.</title>
+<script src="media-file.js"></script>
+<script src="media-controls.js"></script>
+<script src="../resources/testharness.js"></script>
+<script src="../resources/testharnessreport.js"></script>
+<audio controls>
+ <track src="track/captions-webvtt/captions-fast.vtt" default>
+</audio>
+<script>
+async_test(function(t) {
+ var audio = document.querySelector('audio');
+ audio.src = findMediaFile('audio', 'content/test');
+ audio.onloadedmetadata = t.step_func_done(function() {
+ assert_false(isClosedCaptionsButtonVisible(audio));
+ });
+});
+</script>
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/media/audio-controls-captions-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698