Skip to content

Commit

Permalink
Update path in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jgyselov committed Aug 21, 2024
1 parent 029aebb commit ea48c7b
Show file tree
Hide file tree
Showing 9 changed files with 11 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ describe(`Assisted Installer Multinode Cluster Installation`, () => {

beforeEach(() => {
setTestStartSignal('');
cy.visit('/clusters');
cy.visit('/assisted-installer/clusters');
});

describe('Creating a new cluster', () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@ describe(`Assisted Installer SNO Cluster Installation`, () => {

beforeEach(() => {
setTestStartSignal('');
cy.visit('/clusters');
cy.visit('/assisted-installer/clusters');
});

describe('Creating a new cluster', () => {
it('Can go to New Cluster Wizard', () => {
clusterListPage.getCreateNewClusterButton().should('be.visible');
clusterListPage.getCreateNewClusterButton().click();

cy.location('pathname').should('eq', Cypress.env('newClusterLocation'));
cy.location('pathname').should('eq', '/assisted-installer/clusters/~new');
});

it('Can submit the form to create a new cluster', () => {
Expand All @@ -49,7 +49,7 @@ describe(`Assisted Installer SNO Cluster Installation`, () => {
describe('When the cluster is created', () => {
beforeEach(() => {
setTestStartSignal('CLUSTER_CREATED');
cy.visit('/clusters');
cy.visit('/assisted-installer/clusters');
});

it('Lists the new cluster', () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ describe(`Assisted Installer Static IP Cluster Creation`, () => {

beforeEach(() => {
setTestStartSignal('');
cy.visit('/clusters');
cy.visit('/assisted-installer/clusters');
});

describe('Creating a new cluster', () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ describe('Assisted Installer UI behaviour - cluster creation', () => {

beforeEach(() => {
setTestStartSignal('');
cy.visit('/clusters');
cy.visit('/assisted-installer/clusters');
});

describe('OpenShiftVersion tests', () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ describe('Assisted Installer UI behaviour - cluster creation with custom OCP rel

beforeEach(() => {
setTestStartSignal('');
cy.visit('/clusters');
cy.visit('/assisted-installer/clusters');
});

describe('Custom OpenShiftVersion tests', () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ Cypress.env('cpuArchitectureFieldHelperId', '#form-input-cpuArchitecture-field-h
Cypress.env('pullSecretFieldHelperId', '#form-input-pullSecret-field-helper');
Cypress.env('clusterNameFieldHelperId', '#form-input-name-field-helper');
Cypress.env('baseDnsDomainFieldHelperId', '#form-input-baseDnsDomain-field-helper');
Cypress.env('newClusterLocation', '/clusters/~new');
Cypress.env(
'staticIpNetworkConfigFieldId',
'#form-radio-hostsNetworkConfigurationType-static-field',
Expand Down
4 changes: 2 additions & 2 deletions libs/ui-lib-tests/cypress/views/common.ts
Original file line number Diff line number Diff line change
Expand Up @@ -99,10 +99,10 @@ export const commonActions = {
return cy.get('#form-input-dns-field-helper-error');
},
visitNewClusterPage: () => {
cy.visit('/clusters/~new');
cy.visit('/assisted-installer/clusters/~new');
},
visitClusterDetailsPage: () => {
cy.visit(`/clusters/${Cypress.env('clusterId')}`);
cy.visit(`/assisted-installer/clusters/${Cypress.env('clusterId')}`);
cy.get('h2').should('exist');
},
};
2 changes: 1 addition & 1 deletion libs/ui-lib-tests/cypress/views/pages/ClusterPage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ export class ClusterPage {
}

static visit(options?: Partial<Cypress.VisitOptions>) {
cy.visit(`/clusters/${Cypress.env('clusterId')}`, options);
cy.visit(`/assisted-installer/clusters/${Cypress.env('clusterId')}`, options);
}

get body() {
Expand Down
2 changes: 1 addition & 1 deletion libs/ui-lib-tests/cypress/views/pages/NewClusterPage.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
export class NewClusterPage {
static visit(options?: Partial<Cypress.VisitOptions>) {
return cy.visit('/clusters/~new', options);
return cy.visit('/assisted-installer/clusters/~new', options);
}
}

0 comments on commit ea48c7b

Please sign in to comment.