Skip to content

Commit

Permalink
format, update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jenny-s51 committed May 21, 2024
1 parent 0c33597 commit 2958c81
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -311,13 +311,13 @@ describe('Pipeline topology', () => {

it('Test pipeline run duplicate navigation', () => {
pipelineRunDetails.visit(projectId, mockRun.run_id);
pipelineRunDetails.selectActionDropdownItem('Duplicate');
pipelineRunDetails.selectActionDropdownItem('Clone');
verifyRelativeURL(`/pipelineRuns/${projectId}/pipelineRun/clone/${mockRun.run_id}`);
});

it('Test pipeline job duplicate navigation', () => {
pipelineRunJobDetails.visit(projectId, mockJob.recurring_run_id);
pipelineRunJobDetails.selectActionDropdownItem('Duplicate');
pipelineRunJobDetails.selectActionDropdownItem('Clone');
verifyRelativeURL(
`/pipelineRuns/${projectId}/pipelineRun/cloneJob/${mockJob.recurring_run_id}?runType=scheduled`,
);
Expand Down
6 changes: 2 additions & 4 deletions frontend/src/api/pipelines/custom.ts
Original file line number Diff line number Diff line change
Expand Up @@ -235,10 +235,8 @@ export const stopPipelineRun: UpdatePipelineRunAPI = (hostPath) => (opts, runId)
proxyENDPOINT(hostPath, `/apis/v2beta1/runs/${runId}:terminate`, {}, opts),
);

export const retryPipelineRun: UpdatePipelineRunAPI = (hostPath) => (opts, runId) =>
handlePipelineFailures(
proxyENDPOINT(hostPath, `/apis/v2beta1/runs/${runId}:retry`, {}, opts),
);
export const retryPipelineRun: UpdatePipelineRunAPI = (hostPath) => (opts, runId) =>
handlePipelineFailures(proxyENDPOINT(hostPath, `/apis/v2beta1/runs/${runId}:retry`, {}, opts));

export const updatePipelineRunJob: UpdatePipelineRunJobAPI = (hostPath) => (opts, jobId, enabled) =>
handlePipelineFailures(
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/concepts/pipelines/content/utils.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@ export type RunStatusDetails = {
const UNKNOWN_ICON = <QuestionCircleIcon />;
const UNKNOWN_STATUS = 'warning';

export const getStorageState = (run?: PipelineRunKFv2 | null): StorageStateKF | undefined => run?.storage_state;
export const getStorageState = (run?: PipelineRunKFv2 | null): StorageStateKF | undefined =>
run?.storage_state;

export const computeRunStatus = (run?: PipelineRunKFv2 | null): RunStatusDetails => {
if (!run) {
Expand Down

0 comments on commit 2958c81

Please sign in to comment.