Skip to content

Commit ecfb1df

Browse files
Naively update tests.
1 parent 3159f50 commit ecfb1df

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

app/src/organisms/InterventionModal/__tests__/utils.test.ts

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -144,8 +144,7 @@ describe('getRunLabwareRenderInfo', () => {
144144
)
145145
const labwareInfo = res[0]
146146
expect(labwareInfo).toBeTruthy()
147-
expect(labwareInfo.x).toEqual(0) // taken from deckDef fixture
148-
expect(labwareInfo.y).toEqual(0)
147+
expect(labwareInfo.labwareOrigin).toStrictEqual({ x: 0, y: 0, z: 0 }) // taken from deckDef fixture
149148
expect(labwareInfo.labwareDef.metadata.displayName).toEqual(
150149
'NEST 96 Well Plate 100 µL PCR Full Skirt'
151150
)
@@ -173,14 +172,16 @@ describe('getRunLabwareRenderInfo', () => {
173172
labware => labware.labwareId === 'mockLabwareID3'
174173
)
175174
expect(labwareInfo).toBeTruthy()
176-
expect(labwareInfo?.x).toEqual(0)
177-
expect(labwareInfo?.y).toEqual(
178-
ot2DeckDefV5.cornerOffsetFromOrigin[1] -
179-
getSchema2Dimensions(mockLabwareDefinition).yDimension
180-
)
175+
expect(labwareInfo?.labwareOrigin).toStrictEqual({
176+
x: 0,
177+
y:
178+
ot2DeckDefV5.cornerOffsetFromOrigin[1] -
179+
getSchema2Dimensions(mockLabwareDefinition).yDimension,
180+
z: 0,
181+
})
181182
})
182183

183-
it('defaults labware x, y coordinates to 0,0 if slot position not found in deck definition', () => {
184+
it('omits labware if slot position not found in deck definition', () => {
184185
const mockBadSlotLabware = {
185186
id: 'mockBadLabwareID',
186187
loadName: 'nest_96_wellplate_100ul_pcr_full_skirt',
@@ -195,8 +196,7 @@ describe('getRunLabwareRenderInfo', () => {
195196
ot2DeckDefV5 as any
196197
)
197198

198-
expect(res[0].x).toEqual(0)
199-
expect(res[0].y).toEqual(0)
199+
expect(res).toHaveLength(0)
200200
})
201201
})
202202

0 commit comments

Comments
 (0)