Skip to content

Commit 359a001

Browse files
committed
test: prevent false-positive duplicate-name check in argo workflow version test
Signed-off-by: Guilherme Caponetto <638737+caponetto@users.noreply.github.com>
1 parent 07c9785 commit 359a001

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

packages/cypress/cypress/tests/mocked/pipelines/pipelines.cy.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1099,6 +1099,18 @@ describe('Pipelines', () => {
10991099

11001100
it('uploads fails with argo workflow', () => {
11011101
initIntercepts({});
1102+
1103+
// Return empty results for filtered version requests (duplicate-name check)
1104+
// so the generic initIntercepts mock doesn't cause a false-positive.
1105+
cy.intercept(
1106+
{
1107+
method: 'GET',
1108+
pathname: `/api/service/pipelines/${projectName}/dspa/apis/v2beta1/pipelines/test-pipeline/versions`,
1109+
query: { filter: /.*/ },
1110+
},
1111+
{ pipeline_versions: [], total_size: 0 },
1112+
);
1113+
11021114
pipelinesGlobal.visit(projectName);
11031115

11041116
// Wait for the pipelines table to load

0 commit comments

Comments
 (0)