mirror of
https://github.com/cpvalente/ontime.git
synced 2026-08-14 20:03:52 +00:00
Refactor/vite (#209)
* refactor(vite): add dependencies * refactor(vite): necessary code migrations * refactor(vite): convert file to tsx * refactor(vite): config * refactor(vite): doctype casing
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
import { render, screen } from '@testing-library/react';
|
||||
import { vi } from 'vitest';
|
||||
|
||||
import MenuActionButtons from '../MenuActionButtons';
|
||||
|
||||
const actionHandler = vi.fn();
|
||||
const renderInMock = () => {
|
||||
render(<MenuActionButtons actionHandler={actionHandler} />);
|
||||
};
|
||||
|
||||
test('check that menu bar renders correctly', () => {
|
||||
// need to inject the react query provider
|
||||
renderInMock();
|
||||
|
||||
const b = screen.getByRole('button', {
|
||||
name: /create menu/i,
|
||||
});
|
||||
|
||||
expect(b).toBeInTheDocument();
|
||||
});
|
||||
Reference in New Issue
Block a user