@@ -70,6 +70,12 @@ describe('createFile selector', () => {
70
70
afterEach ( ( ) => {
71
71
vi . restoreAllMocks ( )
72
72
} )
73
+ const entities = {
74
+ moduleEntities : v7Fixture . moduleEntities ,
75
+ labwareEntities,
76
+ pipetteEntities,
77
+ liquidEntities : ingredients ,
78
+ }
73
79
it ( 'should return a schema-valid JSON V8 protocol' , ( ) => {
74
80
// @ts -expect-error(sa, 2021-6-15): resultFunc not part of Selector type
75
81
const result = createFile . resultFunc (
@@ -78,16 +84,13 @@ describe('createFile selector', () => {
78
84
v7Fixture . robotStateTimeline ,
79
85
OT2_ROBOT_TYPE ,
80
86
dismissedWarnings ,
81
- ingredients ,
82
87
ingredLocations ,
83
88
v7Fixture . savedStepForms ,
84
89
v7Fixture . orderedStepIds ,
85
- labwareEntities ,
86
- v7Fixture . moduleEntities ,
87
- pipetteEntities ,
88
90
labwareNicknamesById ,
89
91
labwareDefsByURI ,
90
- { }
92
+ { } ,
93
+ entities
91
94
)
92
95
expectResultToMatchSchema ( result )
93
96
@@ -99,7 +102,12 @@ describe('createFile selector', () => {
99
102
100
103
it ( 'should return a valid Python protocol file' , ( ) => {
101
104
// @ts -expect-error(sa, 2021-6-15): resultFunc not part of Selector type
102
- const result = createPythonFile . resultFunc ( fileMetadata , OT2_ROBOT_TYPE , { } )
105
+ const result = createPythonFile . resultFunc (
106
+ fileMetadata ,
107
+ OT2_ROBOT_TYPE ,
108
+ entities ,
109
+ v7Fixture . initialRobotState
110
+ )
103
111
// This is just a quick smoke test to make sure createPythonFile() produces
104
112
// something that looks like a Python file. The individual sections of the
105
113
// generated Python will be tested in separate unit tests.
0 commit comments