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

Unified Diff: third_party/WebKit/LayoutTests/webaudio/AudioParam/audioparam-setTargetAtTime-continuous.html

Issue 2658703002: Convert AudioParam Audit tests to testharness (Closed)
Patch Set: Rebase test Created 3 years, 11 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
Index: third_party/WebKit/LayoutTests/webaudio/AudioParam/audioparam-setTargetAtTime-continuous.html
diff --git a/third_party/WebKit/LayoutTests/webaudio/AudioParam/audioparam-setTargetAtTime-continuous.html b/third_party/WebKit/LayoutTests/webaudio/AudioParam/audioparam-setTargetAtTime-continuous.html
index 17e86a9d1c2aa92a2d3e5324c0f4bd2ef5b1d343..a2d89ef849b1b513d54b48dca46a24e4702c49fb 100644
--- a/third_party/WebKit/LayoutTests/webaudio/AudioParam/audioparam-setTargetAtTime-continuous.html
+++ b/third_party/WebKit/LayoutTests/webaudio/AudioParam/audioparam-setTargetAtTime-continuous.html
@@ -1,7 +1,8 @@
<!doctype html>
<html>
<head>
- <script src="../../resources/js-test.js"></script>
+ <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/audioparam-testing.js"></script>
@@ -10,8 +11,6 @@
<body>
<script>
- description("Test SetTarget Followed by Linear or Exponential Ramp");
- window.jsTestIsAsync = true;
var sampleRate = 48000;
var renderQuantum = 128;
@@ -84,7 +83,6 @@
});
audit.defineTask("finish", function (done) {
- finishJSTest();
done();
});
@@ -209,7 +207,9 @@
length))
.beCloseToArray(expected.setTargetPart, thresholdSetTarget) && success;
} else {
- testPassed("SetTarget part was correctly replaced by the ramp");
+ Should("SetTarget part", !length)
+ .summarize("was correctly replaced by the ramp",
+ "was incorrectly replaced by the ramp");
}
// Verify the ramp part of the curve
@@ -223,10 +223,9 @@
success = Should(prefix + ": Tail part", result.slice(startIndex))
.beCloseToArray(expected.tailPart, 0) && success;
- if (success)
- testPassed(prefix + " preceded by SetTarget is continuous.\n");
- else
- testFailed(prefix + " preceded by SetTarget was not continuous.\n");
+ Should(prefix, success)
+ .summarize("preceded by SetTarget is continuous",
+ "preceded by SetTarget was not continuous");
});
}
</script>

Powered by Google App Engine
This is Rietveld 408576698