diff --git a/test/runtime/samples/binding-audio-currenttime-duration-volume/_config.js b/test/runtime/samples/binding-audio-currenttime-duration-volume/_config.js index 921969179f..0a6754a210 100644 --- a/test/runtime/samples/binding-audio-currenttime-duration-volume/_config.js +++ b/test/runtime/samples/binding-audio-currenttime-duration-volume/_config.js @@ -8,24 +8,29 @@ export default { assert.equal(component.t, 0); assert.equal(component.d, 0); assert.equal(component.v, 0.5); + assert.equal(component.r, 1); assert.equal(component.paused, true); const audio = target.querySelector('audio'); const timeupdate = new window.Event('timeupdate'); const durationchange = new window.Event('durationchange'); const volumechange = new window.Event('volumechange'); + const ratechange = new window.Event('ratechange'); audio.currentTime = 10; audio.duration = 20; audio.volume = 0.75; + audio.playbackRate = 2; audio.dispatchEvent(timeupdate); audio.dispatchEvent(durationchange); audio.dispatchEvent(volumechange); + audio.dispatchEvent(ratechange); audio.play(); assert.equal(component.t, 10); assert.equal(component.d, 0); // not 20, because read-only. Not sure how to test this! assert.equal(component.v, 0.75); + assert.equal(component.r, 2); assert.equal(component.paused, true); // ditto... } }; diff --git a/test/runtime/samples/binding-audio-currenttime-duration-volume/main.svelte b/test/runtime/samples/binding-audio-currenttime-duration-volume/main.svelte index 68bef624bc..69335182e8 100644 --- a/test/runtime/samples/binding-audio-currenttime-duration-volume/main.svelte +++ b/test/runtime/samples/binding-audio-currenttime-duration-volume/main.svelte @@ -3,7 +3,8 @@ export let d; export let paused; export let v; + export let r; - \ No newline at end of file