diff --git a/imports/ui/App.tsx b/imports/ui/App.tsx index 9517451e8..063198083 100644 --- a/imports/ui/App.tsx +++ b/imports/ui/App.tsx @@ -1,6 +1,6 @@ import React from 'react'; -import {BrowserRouter} from 'react-router-dom'; +import {BrowserRouter, Routes, Route} from 'react-router-dom'; import {CacheProvider} from '@emotion/react'; import createCache from '@emotion/cache'; @@ -10,6 +10,8 @@ import {SnackbarProvider} from 'notistack'; import CssBaseline from '@mui/material/CssBaseline'; +import isTest from '../app/isTest'; + import DateTimeLocalizationProvider from './i18n/DateTimeLocalizationProvider'; import CustomWholeWindowDropZone from './input/CustomWholeWindowDropZone'; import ModalProvider from './modal/ModelProvider'; @@ -24,11 +26,22 @@ export const muiCache = createCache({ prepend: true, }); +const Router = isTest() + ? ({children}) => ( + + + test} path="/_test" /> + + + + ) + : BrowserRouter; + const App = () => { const theme = useUserTheme(); return ( - + @@ -47,7 +60,7 @@ const App = () => { - + ); };