Skip to content
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

refactor(app): rename error recovery "hooks" dir to "utils" #15449

Merged
merged 4 commits into from
Jun 18, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
Next Next commit
refactor(app): rename error recovery "hooks" dir to "utils"
  • Loading branch information
mjhuff committed Jun 18, 2024
commit 46cb0e44dd64ed49803b4f482dbeae03b6114d30
2 changes: 1 addition & 1 deletion app/src/organisms/DropTipWizardFlows/types.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import type { DT_ROUTES } from './constants'
import type { DropTipErrorComponents } from './hooks'
import type { DropTipWizardProps } from './DropTipWizard'
import type { ERUtilsResults } from '../ErrorRecoveryFlows/hooks'
import type { ERUtilsResults } from '../ErrorRecoveryFlows/utils'

export type DropTipFlowsRoute = typeof DT_ROUTES[keyof typeof DT_ROUTES]
export type DropTipFlowsStep = DropTipFlowsRoute[number]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
ManageTips,
} from './RecoveryOptions'
import { RecoveryInProgress } from './RecoveryInProgress'
import { getErrorKind } from './hooks'
import { getErrorKind } from './utils'
import { RECOVERY_MAP } from './constants'

import type { RobotType } from '@opentrons/shared-data'
Expand All @@ -27,7 +27,7 @@ import type {
useRouteUpdateActions,
useRecoveryCommands,
ERUtilsResults,
} from './hooks'
} from './utils'
import type { ErrorRecoveryFlowsProps } from '.'

interface UseERWizardResult {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import type {
RecoveryTipStatusUtils,
UseRecoveryCommandsResult,
UseRouteUpdateActionsResult,
} from '../hooks'
} from '../utils'

export function CancelRun({
isOnDevice,
Expand Down
4 changes: 2 additions & 2 deletions app/src/organisms/ErrorRecoveryFlows/RunPausedSplash.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ import {
} from '@opentrons/components'

import { getIsOnDevice } from '../../redux/config'
import { getErrorKind, useErrorMessage, useErrorName } from './hooks'
import { getErrorKind, useErrorMessage, useErrorName } from './utils'
import { LargeButton } from '../../atoms/buttons'
import { RECOVERY_MAP } from './constants'

import type { FailedCommand } from './types'
import type { UseRouteUpdateActionsResult } from './hooks'
import type { UseRouteUpdateActionsResult } from './utils'

export function useRunPausedSplash(): boolean {
return useSelector(getIsOnDevice)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@ import { renderWithProviders } from '../../../__testing-utils__'
import { i18n } from '../../../i18n'
import { mockFailedCommand } from '../__fixtures__'
import { ErrorRecoveryFlows, useErrorRecoveryFlows } from '..'
import { useCurrentlyRecoveringFrom, useERUtils } from '../hooks'
import { useCurrentlyRecoveringFrom, useERUtils } from '../utils'
import { useFeatureFlag } from '../../../redux/config'
import { useERWizard, ErrorRecoveryWizard } from '../ErrorRecoveryWizard'
import { useRunPausedSplash, RunPausedSplash } from '../RunPausedSplash'

import type { RunStatus } from '@opentrons/api-client'

vi.mock('../ErrorRecoveryWizard')
vi.mock('../hooks')
vi.mock('../utils')
vi.mock('../useRecoveryCommands')
vi.mock('../../../redux/config')
vi.mock('../RunPausedSplash')
Expand Down
2 changes: 1 addition & 1 deletion app/src/organisms/ErrorRecoveryFlows/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import { OT2_ROBOT_TYPE } from '@opentrons/shared-data'
import { useFeatureFlag } from '../../redux/config'
import { ErrorRecoveryWizard, useERWizard } from './ErrorRecoveryWizard'
import { RunPausedSplash, useRunPausedSplash } from './RunPausedSplash'
import { useCurrentlyRecoveringFrom, useERUtils } from './hooks'
import { useCurrentlyRecoveringFrom, useERUtils } from './utils'

import type { RunStatus } from '@opentrons/api-client'
import type { CompletedProtocolAnalysis } from '@opentrons/shared-data'
Expand Down
Loading