Skip to content

Commit 3f55a6e

Browse files
committed
Partial e2e fixes
1 parent 3737f3f commit 3f55a6e

1 file changed

Lines changed: 13 additions & 1 deletion

File tree

cypress/e2e/blueprints/nav/fake-cluster.ts

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2528,6 +2528,7 @@ export function generateFakeClusterDataAndIntercepts({
25282528
cy.intercept({
25292529
method: 'GET',
25302530
pathname: '/v1/provisioning.cattle.io.clusters',
2531+
query: { pagesize: '*' }
25312532
}, (req) => {
25322533
req.continue((res) => {
25332534
const localIndex = res.body.data.findIndex((item: any) => item.id.includes('/local'));
@@ -2552,7 +2553,11 @@ export function generateFakeClusterDataAndIntercepts({
25522553
}).as('provCluster');
25532554

25542555
// add extra cluster to the nav list to test https://github.com/rancher/dashboard/issues/10452
2555-
cy.intercept('GET', `/v1/management.cattle.io.clusters?*`, (req) => {
2556+
cy.intercept({
2557+
method: 'GET',
2558+
pathname: '/v1/management.cattle.io.clusters',
2559+
query: { pagesize: '*' }
2560+
}, (req) => {
25562561
req.continue((res) => {
25572562
const localIndex = res.body.data.findIndex((item: any) => item.id.includes('local'));
25582563

@@ -2567,6 +2572,13 @@ export function generateFakeClusterDataAndIntercepts({
25672572
});
25682573
}).as('mgmtClusters');
25692574

2575+
cy.intercept('GET', `/v1/management.cattle.io.clusters/${ fakeNavClusterData.mgmtClusterObj.id }?*`, (req) => {
2576+
req.reply({
2577+
statusCode: 200,
2578+
body: fakeNavClusterData.mgmtClusterObj,
2579+
});
2580+
}).as('provCluster');
2581+
25702582
// intercept counts for fake cluster https://github.com/rancher/dashboard/issues/10452
25712583
cy.intercept('GET', `/k8s/clusters/${ fakeMgmtClusterId }/v1/counts?*`, (req) => {
25722584
req.reply({

0 commit comments

Comments
 (0)