2024-07-03 07:33:48 +00:00
|
|
|
/// <reference types="cypress" />
|
|
|
|
describe('VnBreadcrumbs', () => {
|
|
|
|
const firstCard = '.q-infinite-scroll > :nth-child(1)';
|
|
|
|
const lastBreadcrumb = '.q-breadcrumbs--last > .q-breadcrumbs__el';
|
|
|
|
beforeEach(() => {
|
2024-11-29 09:36:22 +00:00
|
|
|
cy.viewport(1920, 1080);
|
2024-07-03 07:33:48 +00:00
|
|
|
cy.login('developer');
|
|
|
|
cy.visit('/');
|
|
|
|
});
|
|
|
|
|
|
|
|
it('should not be breadcrumbs', () => {
|
|
|
|
cy.get('.q-breadcrumbs').should('not.exist');
|
|
|
|
});
|
|
|
|
|
|
|
|
it('should get the correct breadcrumbs', () => {
|
|
|
|
cy.visit('#/customer/list');
|
|
|
|
cy.get('.q-breadcrumbs__el').should('have.length', 2);
|
|
|
|
|
|
|
|
cy.get(firstCard).click();
|
|
|
|
cy.get(`${lastBreadcrumb} > .q-icon`).should('have.text', 'launch');
|
|
|
|
});
|
|
|
|
});
|