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

Unified Diff: third_party/WebKit/LayoutTests/webaudio/Convolver/convolver-channels.html

Issue 2799763002: Convert Convolver tests to new Audit (Closed)
Patch Set: Created 3 years, 8 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/webaudio/Convolver/convolver-channels.html
diff --git a/third_party/WebKit/LayoutTests/webaudio/Convolver/convolver-channels.html b/third_party/WebKit/LayoutTests/webaudio/Convolver/convolver-channels.html
index d61758ad7a4c76acf5a80b4aed80c7056b80d3a3..ce4ea0f22d4ca361c5d99b8c8d111c8df591c1d4 100644
--- a/third_party/WebKit/LayoutTests/webaudio/Convolver/convolver-channels.html
+++ b/third_party/WebKit/LayoutTests/webaudio/Convolver/convolver-channels.html
@@ -4,7 +4,7 @@
<script src="../../resources/testharness.js"></script>
<script src="../../resources/testharnessreport.js"></script>
<script src="../resources/audit-util.js"></script>
- <script src="../resources/audio-testing.js"></script>
+ <script src="../resources/audit.js"></script>
<title>Test Supported Number of Channels for ConvolverNode</title>
</head>
@@ -13,7 +13,7 @@
var audit = Audit.createTaskRunner();
- audit.defineTask("channel-count-test", function (done) {
+ audit.define("channel-count-test", (task, should) => {
// Just need a context to create nodes on, so any allowed length and rate is ok.
var context = new OfflineAudioContext(1, 1, 48000);
@@ -26,27 +26,20 @@
if (count == 1 || count == 2 || count == 4) {
// These are the only valid channel counts for the buffer.
- success = Should(message, function () {
+ should(function () {
convolver.buffer = buffer;
- }).notThrow() && success;
+ }, message).notThrow();
hongchan 2017/04/07 22:26:45 nit: this could be one liner. should(() => convol
Raymond Toy 2017/04/07 22:44:12 Well, I wrapped .notThrow() to the next line.
} else {
- success = Should(message, function () {
+ should(function () {
convolver.buffer = buffer;
- }).throw("NotSupportedError") && success;
+ }, message).throw("NotSupportedError");
hongchan 2017/04/07 22:26:45 Ditto.
}
}
- Should("Multiple channels for the convolver were handled", success)
- .summarize("correctly", "incorrectly");
-
- done();
+ task.done();
});
- audit.defineTask("finish", function (done) {
- done();
- });
-
- audit.runTasks();
+ audit.run();
</script>
</body>
</html>
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698