Skip to content

Commit

Permalink
test: adjust mime type test
Browse files Browse the repository at this point in the history
  • Loading branch information
OrbisK committed Nov 28, 2024
1 parent b0c39ba commit 2b40051
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions tests/components/UseMediaRecorder.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -113,11 +113,16 @@ describe('useMediaRecorder component', () => {
props: {
constraints: { audio: true },
},
slots: {
default: props => {
return props.mimeType
}
}
})
expect(mediaRecorder.vm.mimeType).toBeUndefined()
await mediaRecorder.vm.start()
expect(mediaRecorder.text().length).toBe(0)
await mediaRecorder.vm.start(1)
await vi.waitFor(() => {
expect(mediaRecorder.vm.mimeType).toBeDefined()
expect(mediaRecorder.text().length).toBeGreaterThan(0)
})
})

Expand Down

0 comments on commit 2b40051

Please sign in to comment.