Merge branch 'main' into v5

This commit is contained in:
daishi 2024-03-09 08:52:19 +09:00
commit b19acdfab7

View File

@ -636,7 +636,17 @@ describe('with redux middleware', () => {
})
})
it('works in non-browser env', async () => {
describe('different envs', () => {
let savedConsoleWarn: any
beforeEach(() => {
savedConsoleWarn = console.warn
console.warn = vi.fn()
})
afterEach(() => {
console.warn = savedConsoleWarn
})
it('works in non-browser env', async () => {
const originalWindow = global.window
global.window = undefined as any
@ -645,9 +655,9 @@ it('works in non-browser env', async () => {
}).not.toThrow()
global.window = originalWindow
})
})
it('works in react native env', async () => {
it('works in react native env', async () => {
const originalWindow = global.window
global.window = {} as any
@ -656,6 +666,7 @@ it('works in react native env', async () => {
}).not.toThrow()
global.window = originalWindow
})
})
it('preserves isRecording after setting from devtools', async () => {