fix(editor): Trial banner does not disappear after sign out (no-changelog) (#6930)
to test in staging use version `PR-6930-ado-990-trial-banner-does-not-disappear-after-sign-out` <img width="875" alt="image" src="https://github.com/n8n-io/n8n/assets/16496553/dfffe60f-bec3-4c48-bd9c-5990c68afa52">
This commit is contained in:
8
cypress/pages/bannerStack.ts
Normal file
8
cypress/pages/bannerStack.ts
Normal file
@@ -0,0 +1,8 @@
|
||||
import { BasePage } from './base';
|
||||
|
||||
export class BannerStack extends BasePage {
|
||||
getters = {
|
||||
banner: () => cy.getByTestId('banner-stack'),
|
||||
};
|
||||
actions = {};
|
||||
}
|
||||
@@ -7,3 +7,4 @@ export * from './settings-users';
|
||||
export * from './settings-log-streaming';
|
||||
export * from './sidebar';
|
||||
export * from './ndv';
|
||||
export * from './bannerStack';
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import { BasePage } from '../base';
|
||||
import { WorkflowsPage } from '../workflows';
|
||||
|
||||
export class MainSidebar extends BasePage {
|
||||
getters = {
|
||||
@@ -9,7 +10,7 @@ export class MainSidebar extends BasePage {
|
||||
workflows: () => this.getters.menuItem('Workflows'),
|
||||
credentials: () => this.getters.menuItem('Credentials'),
|
||||
executions: () => this.getters.menuItem('Executions'),
|
||||
userMenu: () => cy.getByTestId('main-sidebar-user-menu'),
|
||||
userMenu: () => cy.get('div[class="action-dropdown-container"]'),
|
||||
};
|
||||
actions = {
|
||||
goToSettings: () => {
|
||||
@@ -26,5 +27,15 @@ export class MainSidebar extends BasePage {
|
||||
openUserMenu: () => {
|
||||
this.getters.userMenu().find('[role="button"]').last().click();
|
||||
},
|
||||
openUserMenu: () => {
|
||||
this.getters.userMenu().click();
|
||||
},
|
||||
signout: () => {
|
||||
const workflowsPage = new WorkflowsPage();
|
||||
cy.visit(workflowsPage.url);
|
||||
this.actions.openUserMenu();
|
||||
cy.getByTestId('user-menu-item-logout').click();
|
||||
cy.wrap(Cypress.session.clearAllSavedSessions());
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user