test: fix flakey test (#279)

This commit is contained in:
Nolan Lawson 2022-04-17 09:00:15 -07:00 committed by GitHub
parent d66d24c0d4
commit 0a45a5c71e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 6 deletions

View File

@ -17,7 +17,7 @@ describe('properties', () => {
document.body.appendChild(picker)
await tick(20)
await tick(40)
expect(fetch).toHaveBeenCalledTimes(1)
expect(fetch).toHaveBeenLastCalledWith(FR_EMOJI, undefined)
@ -28,7 +28,7 @@ describe('properties', () => {
expect(picker.getAttribute('data-source')).toEqual(null)
document.body.removeChild(picker)
await tick(20)
await tick(40)
})
test('setting initial dataSource', async () => {
@ -37,7 +37,7 @@ describe('properties', () => {
document.body.appendChild(picker)
await tick(20)
await tick(40)
expect(fetch).toHaveBeenCalledTimes(1)
expect(fetch).toHaveBeenLastCalledWith(FR_EMOJI, undefined)
@ -48,7 +48,7 @@ describe('properties', () => {
expect(picker.getAttribute('data-source')).toEqual(null)
document.body.removeChild(picker)
await tick(20)
await tick(40)
})
test('setting initial locale', async () => {
@ -57,7 +57,7 @@ describe('properties', () => {
document.body.appendChild(picker)
await tick(20)
await tick(40)
expect(fetch).toHaveBeenCalledTimes(1)
expect(fetch).toHaveBeenLastCalledWith(DEFAULT_DATA_SOURCE, undefined)
@ -68,6 +68,6 @@ describe('properties', () => {
expect(picker.getAttribute('data-source')).toEqual(null)
document.body.removeChild(picker)
await tick(20)
await tick(40)
})
})