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

Side by Side Diff: third_party/WebKit/LayoutTests/webaudio/Oscillator/osc-sawtooth-sweep-snr.html

Issue 2675973003: Convert Oscillator sweep tests to testharness (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 <html> 2 <html>
3 <head> 3 <head>
4 <title>Test Oscillator Node: sawtooth</title> 4 <title>Test Oscillator Node: sawtooth</title>
5 <script src="../../resources/testharness.js"></script>
6 <script src="../../resources/testharnessreport.js"></script>
7 <script src="../resources/audit-util.js"></script>
8 <script src="../resources/audit.js"></script>
5 <script src="../resources/buffer-loader.js"></script> 9 <script src="../resources/buffer-loader.js"></script>
6 <script src="../../resources/js-test.js"></script>
7 <script src="../resources/oscillator-testing.js"></script> 10 <script src="../resources/oscillator-testing.js"></script>
8 </head> 11 </head>
9 12
10 <body> 13 <body>
11 <script> 14 <script>
12 description("Test Sawtooth Oscillator with Exponential Sweep"); 15 let audit = Audit.createTaskRunner();
16 let tester = OscillatorTestingUtils;
13 17
14 var tester = OscillatorTestingUtils; 18 audit.define("test", (task, should) => {
19 let context = new OfflineAudioContext(1, tester.sampleRate *
20 tester.lengthInSeconds, tester.sampleRate);
15 21
16 // The thresholds are experimentally determined. 22 // The thresholds are experimentally determined.
17 tester.setThresholds({snr: 80.00, maxDiff: 4.06, diffCount: 15827}); 23 tester.setThresholds({
18 tester.runTest("sawtooth"); 24 snr: 80.00,
19 successfullyParsed = true; 25 maxDiff: 4.06,
26 diffCount: 15827
27 });
28 tester.runTest(context, "sawtooth",
29 "Sawtooth Oscillator with Exponential Sweep",
30 task, should);
31 });
32
33 audit.run();
20 </script> 34 </script>
21 </body> 35 </body>
22 </html> 36 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698