mirror of
https://github.com/stablyai/orca.git
synced 2026-10-09 00:02:39 +00:00
15 lines
435 B
TypeScript
15 lines
435 B
TypeScript
import { describe, expect, it } from 'vitest'
|
|
import { websocketPayloadToUint8 } from './websocket-payload-bytes'
|
|
|
|
describe('websocketPayloadToUint8', () => {
|
|
it('returns null when a blob-like payload rejects arrayBuffer conversion', async () => {
|
|
await expect(
|
|
websocketPayloadToUint8({
|
|
arrayBuffer: async () => {
|
|
throw new Error('conversion failed')
|
|
}
|
|
})
|
|
).resolves.toBeNull()
|
|
})
|
|
})
|