Skip to content

Commit

Permalink
update modal reverted
Browse files Browse the repository at this point in the history
  • Loading branch information
mandeepnh5 committed Dec 25, 2024
1 parent 7bc28fc commit 5a13410
Showing 1 changed file with 9 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,13 @@ import { Provider } from 'react-redux';
import { BrowserRouter } from 'react-router-dom';
import { store } from 'state/store';
import i18nForTest from 'utils/i18nForTest';

import { LocalizationProvider } from '@mui/x-date-pickers';
import { AdapterDayjs } from '@mui/x-date-pickers/AdapterDayjs';

import AgendaItemsUpdateModal from './AgendaItemsUpdateModal';
import { toast } from 'react-toastify';
import convertToBase64 from 'utils/convertToBase64';
import type { MockedFunction } from 'vitest';
import { describe, test, expect, vi } from 'vitest';

const mockFormState = {
title: 'Test Title',
Expand Down Expand Up @@ -68,19 +67,19 @@ const mockAgendaItemCategories = [
},
];

const mockHideUpdateModal = vi.fn();
const mockSetFormState = vi.fn();
const mockUpdateAgendaItemHandler = vi.fn();
const mockHideUpdateModal = jest.fn();
const mockSetFormState = jest.fn();
const mockUpdateAgendaItemHandler = jest.fn();
const mockT = (key: string): string => key;

vi.mock('react-toastify', () => ({
jest.mock('react-toastify', () => ({
toast: {
success: vi.fn(),
error: vi.fn(),
success: jest.fn(),
error: jest.fn(),
},
}));
vi.mock('utils/convertToBase64');
const mockedConvertToBase64 = convertToBase64 as MockedFunction<
jest.mock('utils/convertToBase64');
const mockedConvertToBase64 = convertToBase64 as jest.MockedFunction<
typeof convertToBase64
>;

Expand Down

0 comments on commit 5a13410

Please sign in to comment.