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

Side by Side Diff: third_party/WebKit/LayoutTests/webaudio/BiquadFilter/biquad-lowpass.html

Issue 2708953003: Move task.describe descriptions to audit.define (Closed)
Patch Set: Address review comments. 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 unified diff | Download patch
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 2
3 <html> 3 <html>
4 <head> 4 <head>
5 <script src="../../resources/testharness.js"></script> 5 <script src="../../resources/testharness.js"></script>
6 <script src="../../resources/testharnessreport.js"></script> 6 <script src="../../resources/testharnessreport.js"></script>
7 <script src="../resources/audit-util.js"></script> 7 <script src="../resources/audit-util.js"></script>
8 <script src="../resources/audit.js"></script> 8 <script src="../resources/audit.js"></script>
9 <script src="../resources/biquad-filters.js"></script> 9 <script src="../resources/biquad-filters.js"></script>
10 <script src="../resources/biquad-testing.js"></script> 10 <script src="../resources/biquad-testing.js"></script>
11 </head> 11 </head>
12 12
13 <body> 13 <body>
14 <script> 14 <script>
15 let audit = Audit.createTaskRunner(); 15 let audit = Audit.createTaskRunner();
16 16
17 audit.define("test", function (task, should) { 17 audit.define({
18 task.describe("Biquad lowpass filter"); 18 label: "test",
19 description: "Biquad lowpass filter"
20 }, function (task, should) {
19 21
20 // Create offline audio context. 22 // Create offline audio context.
21 let context = new OfflineAudioContext(2, sampleRate * renderLengthSeconds, s ampleRate); 23 let context = new OfflineAudioContext(2, sampleRate * renderLengthSeconds, s ampleRate);
22 24
23 // The filters we want to test. 25 // The filters we want to test.
24 let filterParameters = [{cutoff : 0, q : 1, gain : 1 }, 26 let filterParameters = [{cutoff : 0, q : 1, gain : 1 },
25 {cutoff : 1, q : 1, gain : 1 }, 27 {cutoff : 1, q : 1, gain : 1 },
26 {cutoff : 0.25, q : 1, gain : 1 }, 28 {cutoff : 0.25, q : 1, gain : 1 },
27 {cutoff : 0.25, q : 1, gain : 1, detune : 100 }, 29 {cutoff : 0.25, q : 1, gain : 1, detune : 100 },
28 {cutoff : 0.01, q : 1, gain : 1, detune : -200 }, 30 {cutoff : 0.01, q : 1, gain : 1, detune : -200 },
29 ]; 31 ];
30 32
31 createTestAndRun(context, "lowpass", { 33 createTestAndRun(context, "lowpass", {
32 should: should, 34 should: should,
33 threshold: 9.7869e-8, 35 threshold: 9.7869e-8,
34 filterParameters: filterParameters 36 filterParameters: filterParameters
35 }).then(task.done.bind(task)); 37 }).then(task.done.bind(task));
36 }); 38 });
37 39
38 audit.run(); 40 audit.run();
39 </script> 41 </script>
40 42
41 </body> 43 </body>
42 </html> 44 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698