mirror of
https://github.com/supabase/supabase.git
synced 2026-10-05 09:25:06 +03:00
Fix test
This commit is contained in:
1 parent
7060859a94
commit
349d99aa95
2 files changed
+6
-6
No files matched your search
@@ -70,12 +70,12 @@ test('datepicker onChange will return ISO string of selected dates', async () =>
|
||||
userEvent.clear(toHH)
|
||||
userEvent.type(toHH, '12')
|
||||
|
||||
userEvent.click(await screen.findByText('24'), { selector: '.react-datepicker__day' })
|
||||
userEvent.click(await screen.findByText('25'), { selector: '.react-datepicker__day' })
|
||||
userEvent.click(await screen.findByText('20'), { selector: '.react-datepicker__day' })
|
||||
userEvent.click(await screen.findByText('21'), { selector: '.react-datepicker__day' })
|
||||
userEvent.click(await screen.findByText('Apply'))
|
||||
expect(mockFn).toBeCalled()
|
||||
|
||||
const call = mockFn.mock.calls[0][0]
|
||||
expect(call.to).toMatch(dayjs().date(25).hour(12).utc().format('YYYY-MM-DDTHH'))
|
||||
expect(call.from).toMatch(dayjs().date(24).hour(0).utc().format('YYYY-MM-DDTHH'))
|
||||
expect(call.to).toMatch(dayjs().date(21).hour(12).utc().format('YYYY-MM-DDTHH'))
|
||||
expect(call.from).toMatch(dayjs().date(20).hour(0).utc().format('YYYY-MM-DDTHH'))
|
||||
})
|
||||
@@ -495,8 +495,8 @@ test('datepicker onChange will set the query params for outbound api request', a
|
||||
userEvent.clear(toHH)
|
||||
userEvent.type(toHH, '12')
|
||||
|
||||
userEvent.click(await screen.findByText('24'), { selector: '.react-datepicker__day' })
|
||||
userEvent.click(await screen.findByText('25'), { selector: '.react-datepicker__day' })
|
||||
userEvent.click(await screen.findByText('20'), { selector: '.react-datepicker__day' })
|
||||
userEvent.click(await screen.findByText('21'), { selector: '.react-datepicker__day' })
|
||||
userEvent.click(await screen.findByText('Apply'))
|
||||
|
||||
await waitFor(() => {
|
||||
|
||||
Reference in new issue
Block a user