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

Side by Side Diff: third_party/WebKit/LayoutTests/webaudio/Analyser/realtimeanalyser-byte-data.html

Issue 2595633002: Convert Analyser tests to use testharness (Closed)
Patch Set: Remove blank line Created 3 years, 12 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 unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/webaudio/Analyser/realtimeanalyser-byte-data-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <!doctype html> 1 <!doctype html>
2 <html> 2 <html>
3 <head> 3 <head>
4 <script src="../../resources/js-test.js"></script> 4 <script src="../../resources/testharness.js"></script>
5 <script src="../../resources/testharnessreport.js"></script>
5 <script src="../resources/compatibility.js"></script> 6 <script src="../resources/compatibility.js"></script>
6 <script src="../resources/audit-util.js"></script> 7 <script src="../resources/audit-util.js"></script>
7 <script src="../resources/audio-testing.js"></script> 8 <script src="../resources/audio-testing.js"></script>
8 <title>Test Analyser.getByteTimeDomainData()</title> 9 <title>Test Analyser.getByteTimeDomainData()</title>
9 </head> 10 </head>
10 11
11 <body> 12 <body>
12 <script> 13 <script>
13 description("Test AnalyserNode getByteTimeDomainData");
14 window.jsTestIsAsync = true;
15
16 var sampleRate = 48000; 14 var sampleRate = 48000;
17 // The size of the analyser frame. Anything larger than 128 is ok, but sh ould be long enough 15 // The size of the analyser frame. Anything larger than 128 is ok, but sh ould be long enough
18 // to capture the peaks of the oscillator waveform. 16 // to capture the peaks of the oscillator waveform.
19 var fftSize = 256; 17 var fftSize = 256;
20 // Number of frames to render. Should be greater than the fftSize, but is otherwise 18 // Number of frames to render. Should be greater than the fftSize, but is otherwise
21 // arbitrary. 19 // arbitrary.
22 var renderFrames = 2 * fftSize; 20 var renderFrames = 2 * fftSize;
23 21
24 var audit = Audit.createTaskRunner(); 22 var audit = Audit.createTaskRunner();
25 23
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 85
88 // Verify that all other samples are computed correctly. 86 // Verify that all other samples are computed correctly.
89 Should("Byte data", byteData).beEqualToArray(expected); 87 Should("Byte data", byteData).beEqualToArray(expected);
90 }).then(context.resume.bind(context)) 88 }).then(context.resume.bind(context))
91 89
92 src.start(); 90 src.start();
93 context.startRendering().then(done); 91 context.startRendering().then(done);
94 }); 92 });
95 93
96 audit.defineTask("finish", function (done) { 94 audit.defineTask("finish", function (done) {
97 finishJSTest();
98 done(); 95 done();
99 }); 96 });
100 97
101 audit.runTasks(); 98 audit.runTasks();
102 </script> 99 </script>
103 </body> 100 </body>
104 </html> 101 </html>
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/webaudio/Analyser/realtimeanalyser-byte-data-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698