( read: () => unknown, timeoutMs = 2000, )
| 103 | } |
| 104 | |
| 105 | export async function waitForMissingQueryClient( |
| 106 | read: () => unknown, |
| 107 | timeoutMs = 2000, |
| 108 | ): Promise<void> { |
| 109 | await waitFor(() => { |
| 110 | try { |
| 111 | read() |
| 112 | return false |
| 113 | } catch (error) { |
| 114 | return isMissingQueryClientError(error) |
| 115 | } |
| 116 | }, timeoutMs) |
| 117 | } |
no test coverage detected