n8n/cypress/e2e/35-admin-user-smoke-test.cy.ts

21 lines
444 B
TypeScript

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