(key: string, variables: unknown, data: unknown)
| 1854 | ) |
| 1855 | fireEvent.click(rendered.getByText('Mutations')) |
| 1856 | const execute = (key: string, variables: unknown, data: unknown) => |
| 1857 | queryClient |
| 1858 | .getMutationCache() |
| 1859 | .build(queryClient, { |
| 1860 | mutationKey: [key], |
| 1861 | mutationFn: () => Promise.resolve(data), |
| 1862 | }) |
| 1863 | .execute(variables) |
| 1864 | execute('by-variables', { title: 'Needle' }, 'ok') |
| 1865 | execute('by-data', { title: 'other' }, { id: 'needle-1' }) |
| 1866 | execute('needle-key', { title: 'other' }, 'ok') |
no test coverage detected