Add control room automations and uploader overrides
This commit is contained in:
@@ -4,6 +4,8 @@ import { render, screen } from '@testing-library/react';
|
||||
|
||||
const navigateMock = vi.fn();
|
||||
const selectEventMock = vi.fn();
|
||||
const refetchMock = vi.fn();
|
||||
const activeEventMock = { slug: 'demo-event', settings: { guest_upload_visibility: 'review', control_room: {} } };
|
||||
|
||||
vi.mock('react-router-dom', () => ({
|
||||
useNavigate: () => navigateMock,
|
||||
@@ -36,8 +38,9 @@ vi.mock('../../auth/context', () => ({
|
||||
|
||||
vi.mock('../../context/EventContext', () => ({
|
||||
useEventContext: () => ({
|
||||
activeEvent: { slug: 'demo-event' },
|
||||
activeEvent: activeEventMock,
|
||||
selectEvent: selectEventMock,
|
||||
refetch: refetchMock,
|
||||
}),
|
||||
}));
|
||||
|
||||
@@ -98,6 +101,13 @@ vi.mock('@tamagui/text', () => ({
|
||||
SizableText: ({ children }: { children: React.ReactNode }) => <span>{children}</span>,
|
||||
}));
|
||||
|
||||
vi.mock('@tamagui/switch', () => ({
|
||||
Switch: Object.assign(
|
||||
({ children }: { children: React.ReactNode }) => <div>{children}</div>,
|
||||
{ Thumb: () => <div /> },
|
||||
),
|
||||
}));
|
||||
|
||||
vi.mock('@tamagui/react-native-web-lite', () => ({
|
||||
Pressable: ({
|
||||
children,
|
||||
@@ -143,6 +153,7 @@ vi.mock('../../api', () => ({
|
||||
approveAndLiveShowPhoto: vi.fn(),
|
||||
approveLiveShowPhoto: vi.fn(),
|
||||
clearLiveShowPhoto: vi.fn(),
|
||||
updateEvent: vi.fn(),
|
||||
createEventAddonCheckout: vi.fn(),
|
||||
featurePhoto: vi.fn(),
|
||||
getAddonCatalog: vi.fn().mockResolvedValue([]),
|
||||
|
||||
Reference in New Issue
Block a user