Skip to content

Commit

Permalink
Bug 1534583 [wpt PR 15732] - Added test for charLength field in Speec…
Browse files Browse the repository at this point in the history
…hSynthesisEvent-constructor, a=testonly

Automatic update from web-platform-tests
Add test for charLength in SpeechSynthesisEvent constructor (#15732)

Follows WICG/speech-api#50.
--

wpt-commits: 3531dc2a994d918914e4751b97807ce8d79bf4b7
wpt-pr: 15732
  • Loading branch information
sjdallst2 authored and jgraham committed Apr 1, 2019
1 parent 450e1fb commit 228f6a7
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
const event = new SpeechSynthesisEvent("type", {utterance: utterance});
assert_equals(event.utterance, utterance);
assert_equals(event.charIndex, 0);
assert_equals(event.charLength, 0);
assert_equals(event.elapsedTime, 0);
assert_equals(event.name, "");
}, "SpeechSynthesisEvent with eventInitDict having an utterance");
Expand All @@ -53,6 +54,7 @@
const event = new SpeechSynthesisEvent("type", {
utterance: utterance,
charIndex: 5,
charLength: 3,
elapsedTime: 100,
name: "foo"
});
Expand All @@ -61,6 +63,7 @@
assert_equals(event.type, "type");
assert_equals(event.utterance, utterance);
assert_equals(event.charIndex, 5);
assert_equals(event.charLength, 3);
assert_equals(event.elapsedTime, 100);
assert_equals(event.name, "foo");
}, "SpeechSynthesisEvent with custom eventInitDict");
Expand Down

0 comments on commit 228f6a7

Please sign in to comment.