Index: third_party/WebKit/LayoutTests/webaudio/AudioBufferSource/audiosource-onended.html |
diff --git a/third_party/WebKit/LayoutTests/webaudio/AudioBufferSource/audiosource-onended.html b/third_party/WebKit/LayoutTests/webaudio/AudioBufferSource/audiosource-onended.html |
index a81133b2c9cbd3673a141ca3b319ad4d78b38ff1..f5b0e3f5c75be9e0110a4be1266342298cb91041 100644 |
--- a/third_party/WebKit/LayoutTests/webaudio/AudioBufferSource/audiosource-onended.html |
+++ b/third_party/WebKit/LayoutTests/webaudio/AudioBufferSource/audiosource-onended.html |
@@ -2,15 +2,14 @@ |
<html> |
<head> |
<title>Test Onended Event Listener</title> |
- <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> |
</head> |
<body> |
<script> |
- description("Test onended event listener"); |
- window.jsTestIsAsync = true; |
var sampleRate = 44100; |
var renderLengthSeconds = 1; |
@@ -32,7 +31,8 @@ |
source.buffer = buffer; |
source.connect(context.destination); |
source.onended = function (e) { |
- testPassed("AudioBufferSource.onended called when ended set directly."); |
+ Should("AudioBufferSource.onended called when ended set directly", true) |
+ .beEqualTo(true); |
}; |
source.start(); |
context.startRendering().then(done); |
@@ -47,7 +47,8 @@ |
source.buffer = buffer; |
source.connect(context.destination); |
source.addEventListener("ended", function (e) { |
- testPassed("AudioBufferSource.onended called when using addEventListener."); |
+ Should("AudioBufferSource.onended called when using addEventListener", |
+ true).beEqualTo(true); |
}); |
source.start(); |
context.startRendering().then(done); |
@@ -60,7 +61,7 @@ |
var source = context.createOscillator(); |
source.connect(context.destination); |
source.onended = function (e) { |
- testPassed("Oscillator.onended called when ended set directly."); |
+ Should("Oscillator.onended called when ended set directly", true).beEqualTo(true); |
}; |
source.start(); |
source.stop(stopTime); |
@@ -74,7 +75,7 @@ |
var source = context.createOscillator(); |
source.connect(context.destination); |
source.addEventListener("ended", function (e) { |
- testPassed("Oscillator.onended called when using addEventListener."); |
+ Should("Oscillator.onended called when using addEventListener", true).beEqualTo(true); |
}); |
source.start(); |
source.stop(stopTime); |
@@ -82,7 +83,6 @@ |
}); |
audit.defineTask("finish", function (done) { |
- finishJSTest(); |
done(); |
}); |