Skip to content

feat(protocol-designer): remove warning for disposal volume #19090

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: edge
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 1 addition & 7 deletions protocol-designer/src/steplist/formLevel/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,6 @@ import {
wellRatioMoveLiquid,
} from './errors'
import {
belowPipetteMinimumVolume,
composeWarnings,
incompatibleLiquidClass,
maxDispenseWellVolume,
Expand Down Expand Up @@ -184,11 +183,7 @@ const stepFormHelperMap: {
transferVolumeMin,
pipetteRequired
),
getWarnings: composeWarnings(
belowPipetteMinimumVolume,
mixTipPositionInTube,
incompatibleLiquidClass
),
getWarnings: composeWarnings(mixTipPositionInTube, incompatibleLiquidClass),
},
pause: {
getErrors: composeErrors(
Expand Down Expand Up @@ -242,7 +237,6 @@ const stepFormHelperMap: {
disposalVolumeRequired
),
getWarnings: composeWarnings(
belowPipetteMinimumVolume,
maxDispenseWellVolume,
tipPositionInTube,
incompatibleLiquidClass
Expand Down
43 changes: 0 additions & 43 deletions protocol-designer/src/steplist/formLevel/test/warnings.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import {
} from '@opentrons/shared-data'

import {
belowPipetteMinimumVolume,
incompatibleLiquidClass,
maxDispenseWellVolume,
mixTipPositionInTube,
Expand All @@ -25,48 +24,6 @@ vi.mock('@opentrons/shared-data', async () => {
}
})

describe('Below pipette minimum volume', () => {
let fieldsWithPipette: {
pipette: { spec: { liquids: { default: { minVolume: number } } } }
}
beforeEach(() => {
fieldsWithPipette = {
pipette: {
spec: {
liquids: {
default: {
minVolume: 100,
},
},
},
},
}
})
it('should NOT return a warning when the volume equals the min pipette volume', () => {
const fields = {
...fieldsWithPipette,
volume: 100,
} as any
expect(belowPipetteMinimumVolume(fields)).toBe(null)
})
it('should NOT return a warning when the volume is greater than the min pipette volume', () => {
const fields = {
...fieldsWithPipette,
volume: 101,
} as any
expect(belowPipetteMinimumVolume(fields)).toBe(null)
})
it('should return a warning when the volume is less than the min pipette volume', () => {
const fields = {
...fieldsWithPipette,
volume: 99,
}
// @ts-expect-error(sa, 2021-6-15): belowPipetteMinimumVolume might return null, need to null check before property access
expect(belowPipetteMinimumVolume(fields).type).toBe(
'BELOW_PIPETTE_MINIMUM_VOLUME'
)
})
})
describe('Max dispense well volume', () => {
let fieldsWithDispenseLabware: any
beforeEach(() => {
Expand Down
Loading