Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
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
17 changes: 8 additions & 9 deletions frontend/packages/console-app/src/plugin.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ import {
getControlPlaneHealth,
getClusterOperatorHealthStatus,
} from './components/dashboards-page/status';
// import { getGuidedTour } from './components/guided-tour';
import { getGuidedTour } from './components/guided-tour';
import { USER_PREFERENCES_BASE_URL } from './components/user-preferences/const';
import * as models from './models';
import {
Expand Down Expand Up @@ -271,14 +271,13 @@ const plugin: Plugin<ConsumedExtensions> = [
).then((m) => m.ConsolePluginManifestPage),
},
},
// @vikram-raj Disable it for now as e2e are failing because of it. Will re-enable it once we fix the e2e.
// {
// type: 'GuidedTour',
// properties: {
// perspective: 'admin',
// tour: getGuidedTour(),
// },
// },
{
type: 'GuidedTour',
properties: {
perspective: 'admin',
tour: getGuidedTour(),
},
},
];

export default plugin;
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
import { guidedTour } from '@console/cypress-integration-tests/views/guided-tour';

/* eslint-disable no-console, promise/catch-or-return */
before(() => {
cy.login();
cy.document().its('readyState').should('eq', 'complete');
guidedTour.close();
});

after(() => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { Given } from 'cypress-cucumber-preprocessor/steps';
import { guidedTour } from '@console/cypress-integration-tests/views/guided-tour';
import { operators } from '../../constants';
import {
installPipelinesOperatorUsingCLI,
Expand All @@ -25,6 +26,7 @@ Given(
(operator: operators, namespace: string) => {
cy.logout();
cy.login(); // make sure we are logged in as kubeadmin
guidedTour.close();
verifyAndInstallOperator(operator, namespace);
},
);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { Given, When, Then } from 'cypress-cucumber-preprocessor/steps';
import { guidedTour } from '@console/cypress-integration-tests/views/guided-tour';
import { modal } from '@console/cypress-integration-tests/views/modal';
import { nav } from '@console/cypress-integration-tests/views/nav';
import {
Expand Down Expand Up @@ -116,5 +117,6 @@ Given('user is at Add page', () => {
Given('user has logged in as admin user', () => {
cy.login();
perspective.switchTo(switchPerspective.Administrator);
guidedTour.close();
nav.sidenav.switcher.shouldHaveText(switchPerspective.Administrator);
});
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { checkErrors, testName } from '../../support';
import { detailsPage } from '../../views/details-page';
import { guidedTour } from '../../views/guided-tour';
import { listPage } from '../../views/list-page';
import * as yamlEditor from '../../views/yaml-editor';

Expand Down Expand Up @@ -28,6 +29,7 @@ spec:
describe('Debug pod', () => {
before(() => {
cy.login();
guidedTour.close();
cy.createProjectWithCLI(testName);
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import { checkErrors } from '../../support';
import { isLocalDevEnvironment } from '../../views/common';
import { detailsPage } from '../../views/details-page';
import { refreshWebConsoleLink } from '../../views/form';
import { guidedTour } from '../../views/guided-tour';
import { listPage } from '../../views/list-page';
import { modal } from '../../views/modal';
import { nav } from '../../views/nav';
Expand Down Expand Up @@ -85,6 +86,7 @@ if (!Cypress.env('OPENSHIFT_CI') || Cypress.env('PLUGIN_PULL_SPEC')) {
describe('Demo dynamic plugin test', () => {
before(() => {
cy.login();
guidedTour.close();
cy.createProjectWithCLI(PLUGIN_NAME);
cy.readFile(`${PLUGIN_PATH}/oc-manifest.yaml`).then((textManifest) => {
const yamlManifest = safeLoadAll(textManifest);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { safeLoad, safeDump } from 'js-yaml';
import * as _ from 'lodash';
import { checkErrors, testName } from '../../support';
import { detailsPage } from '../../views/details-page';
import { guidedTour } from '../../views/guided-tour';
import { listPage } from '../../views/list-page';
import { modal } from '../../views/modal';
import * as yamlEditor from '../../views/yaml-editor';
Expand All @@ -12,6 +13,7 @@ describe('Filtering and Searching', () => {

before(() => {
cy.login();
guidedTour.close();
cy.createProjectWithCLI(testName);
cy.visit(`/k8s/ns/${testName}/deployments`);
listPage.clickCreateYAMLbutton();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
import { checkErrors } from '../../support';
import { isLocalDevEnvironment } from '../../views/common';
import { guidedTour } from '../../views/guided-tour';
import { masthead } from '../../views/masthead';

describe('Masthead', () => {
before(() => {
// clear any existing sessions
Cypress.session.clearAllSavedSessions();
cy.login();
guidedTour.close();
});

afterEach(() => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import { checkErrors } from '../../support';
import { detailsPage } from '../../views/details-page';
import { guidedTour } from '../../views/guided-tour';
import { listPage } from '../../views/list-page';

describe('Node terminal', () => {
before(() => {
cy.login();
guidedTour.close();
});

beforeEach(() => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import {
} from '../../../../public/models';
import { checkErrors, testName } from '../../support';
import { detailsPage } from '../../views/details-page';
import { guidedTour } from '../../views/guided-tour';
import { masthead } from '../../views/masthead';
import { overviewPage } from '../../views/overview';
import * as yamlEditor from '../../views/yaml-editor';
Expand All @@ -23,6 +24,7 @@ const overviewResources = ImmutableSet([
describe('Visiting Overview page', () => {
before(() => {
cy.login();
guidedTour.close();
cy.createProjectWithCLI(testName);
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ const checkConsoleUpdateToast = () => {
describe('PollConsoleUpdates Test', () => {
before(() => {
cy.login();
guidedTour.close();
});

afterEach(() => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import { checkErrors } from '../../support';
import { detailsPage } from '../../views/details-page';
import { guidedTour } from '../../views/guided-tour';
import { listPage, listPage } from '../../views/list-page';

describe('Pod log viewer tab', () => {
before(() => {
cy.login();
guidedTour.close();
});

afterEach(() => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { checkErrors, testName } from '../../support';
import { detailsPage } from '../../views/details-page';
import { guidedTour } from '../../views/guided-tour';
import { listPage } from '../../views/list-page';
import * as yamlEditor from '../../views/yaml-editor';

Expand Down Expand Up @@ -28,6 +29,7 @@ spec:
describe('Start a Job from a CronJob', () => {
before(() => {
cy.login();
guidedTour.close();
cy.createProjectWithCLI(testName);
});

Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
import { checkErrors, testName } from '../../support';
import { guidedTour } from '../../views/guided-tour';
import { oauth } from '../../views/oauth';

describe('OAuth', () => {
let originalOAuthConfig: any;

before(() => {
cy.login();
guidedTour.close();
cy.exec('oc get oauths cluster -o json').then((result) => {
originalOAuthConfig = JSON.parse(result.stdout);
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import * as _ from 'lodash';
import { testName, checkErrors } from '../../support';
import { detailsPage } from '../../views/details-page';
import { submitButton } from '../../views/form';
import { guidedTour } from '../../views/guided-tour';
import { listPage } from '../../views/list-page';
import * as yamlEditor from '../../views/yaml-editor';

Expand All @@ -20,6 +21,7 @@ const resourceObjs =
describe('Add storage is applicable for all workloads', () => {
before(() => {
cy.login();
guidedTour.close();
cy.createProjectWithCLI(testName);
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import { defaultsDeep } from 'lodash';
import { checkErrors, testName } from '../../support';
import { projectDropdown } from '../../views/common';
import { detailsPage } from '../../views/details-page';
import { guidedTour } from '../../views/guided-tour';
import { listPage } from '../../views/list-page';
import { modal } from '../../views/modal';
import { nav } from '../../views/nav';
Expand Down Expand Up @@ -95,6 +96,7 @@ const annotations = [
describe('Annotations', () => {
before(() => {
cy.login();
guidedTour.close();
cy.createProjectWithCLI(testName);
createExampleConfigMapInstance();
});
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { checkErrors, testName } from '../../support';
import { guidedTour } from '../../views/guided-tour';
import * as yamlEditor from '../../views/yaml-editor';

describe('Bulk import operation', () => {
Expand Down Expand Up @@ -73,6 +74,7 @@ stringData:

before(() => {
cy.login();
guidedTour.close();
cy.createProjectWithCLI(namespace);
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { safeLoad, safeDump } from 'js-yaml';
import * as _ from 'lodash';
import { CustomResourceDefinitionKind } from '@console/internal/module/k8s';
import { checkErrors, testName } from '../../support';
import { guidedTour } from '../../views/guided-tour';
import { listPage } from '../../views/list-page';
import * as yamlEditor from '../../views/yaml-editor';

Expand Down Expand Up @@ -71,6 +72,7 @@ describe('CustomResourceDefinitions', () => {

before(() => {
cy.login();
guidedTour.close();
cy.createProjectWithCLI(testName);
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import * as _ from 'lodash';
import { checkErrors, testName } from '../../support';
import { detailsPage } from '../../views/details-page';
import { environment } from '../../views/environment';
import { guidedTour } from '../../views/guided-tour';
import { listPage } from '../../views/list-page';
import * as yamlEditor from '../../views/yaml-editor';

Expand All @@ -11,6 +12,7 @@ const WORKLOAD_NAME = `filter-${testName}`;
describe('Interacting with the environment variable editor', () => {
before(() => {
cy.login();
guidedTour.close();
cy.createProjectWithCLI(testName);
cy.visit(`/k8s/ns/${testName}/deployments`);
listPage.clickCreateYAMLbutton();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { checkErrors, testName } from '../../support';
import { projectDropdown } from '../../views/common';
import { guidedTour } from '../../views/guided-tour';
import { listPage } from '../../views/list-page';
import { nav } from '../../views/nav';

Expand Down Expand Up @@ -51,6 +52,7 @@ describe('Create image pull secret', () => {

before(() => {
cy.login();
guidedTour.close();
cy.createProjectWithCLI(testName);
});

Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
import { checkErrors, testName } from '../../support';
import { projectDropdown } from '../../views/common';
import { detailsPage } from '../../views/details-page';
import { guidedTour } from '../../views/guided-tour';
import { listPage } from '../../views/list-page';
import { modal } from '../../views/modal';
import { nav } from '../../views/nav';

describe('Namespace', () => {
before(() => {
cy.login();
guidedTour.close();
cy.createProjectWithCLI(testName);
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import { nav } from '../../views/nav';
describe('Visiting other routes', () => {
before(() => {
cy.login();
guidedTour.close();
});

afterEach(() => {
Expand Down Expand Up @@ -129,6 +130,7 @@ describe('Visiting other routes', () => {
describe('Test perspective query parameters', () => {
before(() => {
cy.login();
guidedTour.close();
});

beforeEach(() => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import * as _ from 'lodash';
import { checkErrors, testName } from '../../support';
import { projectDropdown } from '../../views/common';
import { detailsPage } from '../../views/details-page';
import { guidedTour } from '../../views/guided-tour';
import { listPage } from '../../views/list-page';
import { modal } from '../../views/modal';
import { nav } from '../../views/nav';
Expand Down Expand Up @@ -85,6 +86,7 @@ const deleteClusterExamples = () => {
describe('Quotas', () => {
before(() => {
cy.login();
guidedTour.close();
cy.createProjectWithCLI(testName);
createExampleQuotas();
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import * as _ from 'lodash';
import { testName, editKind, deleteKind, checkErrors } from '../../support';
import { projectDropdown } from '../../views/common';
import { detailsPage, DetailsPageSelector } from '../../views/details-page';
import { guidedTour } from '../../views/guided-tour';
import { listPage, ListPageSelector } from '../../views/list-page';
import { modal } from '../../views/modal';
import * as yamlEditor from '../../views/yaml-editor';
Expand All @@ -19,6 +20,7 @@ type TestDefinition = {
describe('Kubernetes resource CRUD operations', () => {
before(() => {
cy.login();
guidedTour.close();
cy.createProjectWithCLI(testName);
});

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import * as _ from 'lodash';
import { DeploymentKind } from '@console/internal/module/k8s';
import { checkErrors, testName } from '../../../support';
import { guidedTour } from '../../../views/guided-tour';
import { modal } from '../../../views/modal';
import { secrets } from '../../../views/secret';

Expand Down Expand Up @@ -43,6 +44,7 @@ const deployment: DeploymentKind = {
describe('Add Secret to Workloads', () => {
before(() => {
cy.login();
guidedTour.close();
cy.createProjectWithCLI(testName);
cy.exec(`echo '${JSON.stringify(deployment)}' | kubectl create -n ${testName} -f -`);
cy.exec(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
import { checkErrors, testName } from '../../../support';
import { detailsPage } from '../../../views/details-page';
import { guidedTour } from '../../../views/guided-tour';
import { secrets } from '../../../views/secret';

const heading = 'Create image pull secret';

describe('Image pull secrets', () => {
before(() => {
cy.login();
guidedTour.close();
cy.createProjectWithCLI(testName);
});

Expand Down
Loading