File tree 1 file changed +7
-5
lines changed
public/pages/workflow_detail
1 file changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -28,7 +28,13 @@ jest.mock('../../services', () => {
28
28
} ;
29
29
} ) ;
30
30
31
- const history = createMemoryHistory ( ) ;
31
+ const workflowId = '12345' ;
32
+ const workflowName = 'test_workflow' ;
33
+
34
+ const history = createMemoryHistory ( {
35
+ initialEntries : [ `/workflow/${ workflowId } ` ] ,
36
+ } ) ;
37
+
32
38
window . ResizeObserver = resizeObserverMock ;
33
39
34
40
const renderWithRouter = (
@@ -46,16 +52,12 @@ const renderWithRouter = (
46
52
return < WorkflowDetail setActionMenu = { jest . fn ( ) } { ...props } /> ;
47
53
} }
48
54
/>
49
- < Redirect from = "/" to = { `/workflow/${ workflowId } ` } />
50
55
</ Switch >
51
56
</ Router >
52
57
</ Provider >
53
58
) ,
54
59
} ) ;
55
60
56
- const workflowId = '12345' ;
57
- const workflowName = 'test_workflow' ;
58
-
59
61
describe ( 'WorkflowDetail' , ( ) => {
60
62
Object . values ( WORKFLOW_TYPE ) . forEach ( ( type ) => {
61
63
test ( `renders the page with ${ type } type` , ( ) => {
You can’t perform that action at this time.
0 commit comments