audio: skip TestNonSeekableSource on browsers

This commit is contained in:
Hajime Hoshi 2024-07-14 00:53:58 +09:00
parent 0963b8a7e3
commit bf90217e68

View File

@ -124,6 +124,10 @@ func (emptySource) Read(buf []byte) (int, error) {
} }
func TestNonSeekableSource(t *testing.T) { func TestNonSeekableSource(t *testing.T) {
if runtime.GOOS == "js" {
t.Skip("infinite steams in tests cannot be treated well on browsers")
}
setup() setup()
defer teardown() defer teardown()
@ -134,8 +138,6 @@ func TestNonSeekableSource(t *testing.T) {
p.Play() p.Play()
p.Pause() p.Pause()
p = nil
runtime.GC()
// 200[ms] should be enough all the bytes are consumed. // 200[ms] should be enough all the bytes are consumed.
// TODO: This is a dirty hack. Would it be possible to use virtual time? // TODO: This is a dirty hack. Would it be possible to use virtual time?