mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-13 22:54:42 -04:00
fix(frontend): Add generic type to act calls to trigger promise generation
Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
This commit is contained in:
parent
e5359a69ca
commit
9c3858797f
6 changed files with 11 additions and 11 deletions
|
@ -17,7 +17,7 @@ describe('Settings On-Off Button Group', () => {
|
|||
const view = render(<OnOffButtonGroup value={value} onSelect={onSelect} />)
|
||||
expect(view.container).toMatchSnapshot()
|
||||
const onButton = await screen.findByTestId('onOffButtonGroupOn')
|
||||
await act(() => {
|
||||
await act<void>(() => {
|
||||
onButton.click()
|
||||
})
|
||||
expect(value).toBeTruthy()
|
||||
|
@ -25,7 +25,7 @@ describe('Settings On-Off Button Group', () => {
|
|||
view.rerender(<OnOffButtonGroup value={value} onSelect={onSelect} />)
|
||||
expect(view.container).toMatchSnapshot()
|
||||
const offButton = await screen.findByTestId('onOffButtonGroupOff')
|
||||
await act(() => {
|
||||
await act<void>(() => {
|
||||
offButton.click()
|
||||
})
|
||||
expect(value).toBeFalsy()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue