Index: third_party/WebKit/LayoutTests/webaudio/AudioBufferSource/note-grain-on-timing.html |
diff --git a/third_party/WebKit/LayoutTests/webaudio/AudioBufferSource/note-grain-on-timing.html b/third_party/WebKit/LayoutTests/webaudio/AudioBufferSource/note-grain-on-timing.html |
index 7c87d5daf5649bf9c78823deb1f388f064a652dc..b20c173e33351ae7214fab876753c0a5e7de1a69 100644 |
--- a/third_party/WebKit/LayoutTests/webaudio/AudioBufferSource/note-grain-on-timing.html |
+++ b/third_party/WebKit/LayoutTests/webaudio/AudioBufferSource/note-grain-on-timing.html |
@@ -1,47 +1,47 @@ |
-<!doctype> |
+<!DOCTYPE html> |
<html> |
<head> |
+ <title> |
+ note-grain-on-timing.html |
+ </title> |
<script src="../../resources/testharness.js"></script> |
<script src="../../resources/testharnessreport.js"></script> |
<script src="../resources/audit-util.js"></script> |
<script src="../resources/audit.js"></script> |
<script src="../resources/note-grain-on-testing.js"></script> |
</head> |
- |
<body> |
- <script> |
+ <script id="layout-test-code"> |
let audit = Audit.createTaskRunner(); |
let squarePulseBuffer; |
function checkResult(buffer, should) { |
- renderedData = buffer.getChannelData(0); |
- let nSamples = renderedData.length; |
- let startEndFrames = findStartAndEndSamples(renderedData); |
+ renderedData = buffer.getChannelData(0); |
+ let nSamples = renderedData.length; |
+ let startEndFrames = findStartAndEndSamples(renderedData); |
- verifyStartAndEndFrames(startEndFrames, should); |
+ verifyStartAndEndFrames(startEndFrames, should); |
} |
- audit.define("Test timing of noteGrainOn", function (task, should) { |
- // Create offline audio context. |
- context = new OfflineAudioContext(2, sampleRate * renderTime, |
- sampleRate); |
+ audit.define('Test timing of noteGrainOn', function(task, should) { |
+ // Create offline audio context. |
+ context = |
+ new OfflineAudioContext(2, sampleRate * renderTime, sampleRate); |
- squarePulseBuffer = createSignalBuffer(context, function (k) { |
- return 1 |
- }); |
+ squarePulseBuffer = createSignalBuffer(context, function(k) { |
+ return 1 |
+ }); |
- playAllGrains(context, squarePulseBuffer, numberOfTests); |
+ playAllGrains(context, squarePulseBuffer, numberOfTests); |
- context.startRendering() |
- .then(function (audioBuffer) { |
- checkResult(audioBuffer, should); |
- task.done(); |
- }); |
+ context.startRendering().then(function(audioBuffer) { |
+ checkResult(audioBuffer, should); |
+ task.done(); |
+ }); |
}); |
- |
+ |
audit.run(); |
</script> |
- |
</body> |
</html> |