mirror of
https://github.com/HeyPuter/firefox.git
synced 2026-11-13 20:14:57 -10:00
Automatic update from web-platform-tests Add SpeechRecognition-basics.https.html to chrome.filter Add tests for the basic attributes and fix typos Bug: 393483587 Change-Id: I76a529ae1bc1da80daa42a2d308b79b6b21a0d6a Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6292459 Reviewed-by: Evan Liu <[email protected]> Commit-Queue: Yiren Wang <[email protected]> Cr-Commit-Position: refs/heads/main@{#1423408} -- wpt-commits: 49fb90991e7d13ec8c71bde510c832edbb56b18e wpt-pr: 50887
41 lines
1.1 KiB
HTML
41 lines
1.1 KiB
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<title>SpeechRecognition.stop</title>
|
|
<script src="/resources/testharness.js"></script>
|
|
<script src="/resources/testharnessreport.js"></script>
|
|
<script src="webspeech.js"></script>
|
|
</head>
|
|
<body>
|
|
<p><b>Instructions:</b> Do NOT speak. Run test in silence.
|
|
This test may fail if too much noise.</p>
|
|
<div id="log"></div>
|
|
<div id="notes"></div>
|
|
<script>
|
|
var audioTest = new CycleTest('onaudio');
|
|
reco.onaudiostart = audioTest.startEvent();
|
|
reco.onaudioend = audioTest.endEvent();
|
|
|
|
reco.onsoundstart = neverFireEvent('onsoundstart');
|
|
reco.onsoundend = neverFireEvent('onsoundend');
|
|
reco.onspeechstart = neverFireEvent('onspeechstart');
|
|
reco.onspeechend = neverFireEvent('onspeechend');
|
|
reco.onresult = neverFireEvent('onresult');
|
|
reco.onerror = neverFireEvent('onerror');
|
|
|
|
var nomatchTest = new CountTest('onnomatch', 0, 1);
|
|
reco.onnomatch = nomatchTest.test().step_func(function(event) {
|
|
nomatchTest.count(1);
|
|
});
|
|
|
|
reco.start();
|
|
|
|
function beginTest() {
|
|
setTimeout(function() { reco.stop(); }, DELAY);
|
|
}
|
|
</script>
|
|
</body>
|
|
</html>
|
|
|