n8n/cypress/e2e/35-admin-user-smoke-test.cy.ts
कारतोफ्फेलस्क्रिप्ट™ 3d0393c739
ci: Refactor e2e tests to be less flaky (no-changelog) (#9695)
2024-06-11 14:45:15 +02:00

23 lines
547 B
TypeScript

import { SettingsPage } from '../pages/settings';
const settingsPage = new SettingsPage();
describe('Admin user', { disableAutoLogin: true }, () => {
it('should see same Settings sub menu items as instance owner', () => {
cy.signinAsOwner();
cy.visit(settingsPage.url);
let ownerMenuItems = 0;
settingsPage.getters.menuItems().then(($el) => {
ownerMenuItems = $el.length;
});
cy.signout();
cy.signinAsAdmin();
cy.visit(settingsPage.url);
settingsPage.getters.menuItems().should('have.length', ownerMenuItems);
});
});