This commit is contained in:
parent
6f959ff99c
commit
5f0c4fea3c
|
@ -272,6 +272,7 @@ const openTicketsDialog = (id) => {
|
||||||
</QDialog>
|
</QDialog>
|
||||||
<VnSubToolbar />
|
<VnSubToolbar />
|
||||||
<VnTable
|
<VnTable
|
||||||
|
class="route-list"
|
||||||
ref="tableRef"
|
ref="tableRef"
|
||||||
data-key="RouteList"
|
data-key="RouteList"
|
||||||
url="Routes/filter"
|
url="Routes/filter"
|
||||||
|
|
|
@ -0,0 +1,13 @@
|
||||||
|
describe('RoadMap', () => {
|
||||||
|
beforeEach(() => {
|
||||||
|
cy.viewport(1920, 1080);
|
||||||
|
cy.login('developer');
|
||||||
|
cy.visit(`/#/route/roadmap`);
|
||||||
|
});
|
||||||
|
it('Route list create roadmap and redirect', () => {
|
||||||
|
cy.get('.q-page-sticky > div > .q-btn > .q-btn__content > .q-icon').click();
|
||||||
|
cy.get('input[name="name"]').eq(1).type('roadMapTestOne{enter}');
|
||||||
|
cy.get('.q-notification__message').should('have.text', 'Data created');
|
||||||
|
cy.url().should('include', '/summary');
|
||||||
|
});
|
||||||
|
});
|
|
@ -4,12 +4,28 @@ describe('Route', () => {
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/route/list`);
|
cy.visit(`/#/route/list`);
|
||||||
});
|
});
|
||||||
|
const getVnSelect =
|
||||||
|
'> :nth-child(1) > .column > .q-field > .q-field__inner > .q-field__control > .q-field__control-container';
|
||||||
|
const getRowColumn = (row, column) => `:nth-child(${row}) > :nth-child(${column})`;
|
||||||
|
|
||||||
it('Route list create route', () => {
|
it('Route list create route', () => {
|
||||||
cy.visit(`/#/route/list`);
|
|
||||||
cy.get('.q-page-sticky > div > .q-btn > .q-btn__content > .q-icon').click();
|
cy.get('.q-page-sticky > div > .q-btn > .q-btn__content > .q-icon').click();
|
||||||
cy.get('input[name="description"]').eq(1).type('routeTestOne{enter}');
|
cy.get('input[name="description"]').eq(1).type('routeTestOne{enter}');
|
||||||
cy.get('.q-notification__message').should('have.text', 'Data created');
|
cy.get('.q-notification__message').should('have.text', 'Data created');
|
||||||
cy.url().should('include', '/summary');
|
cy.url().should('include', '/summary');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it('Route list search and edit', () => {
|
||||||
|
cy.get('input[name="description"]').type('routeTestOne{enter}');
|
||||||
|
cy.get('.q-table tr')
|
||||||
|
.its('length')
|
||||||
|
.then((rowCount) => {
|
||||||
|
expect(rowCount).to.be.greaterThan(0);
|
||||||
|
});
|
||||||
|
cy.get(getRowColumn(1, 3) + getVnSelect).type('{downArrow}{enter}');
|
||||||
|
cy.get(getRowColumn(1, 4) + getVnSelect).type('{downArrow}{enter}');
|
||||||
|
cy.get(getRowColumn(1, 5) + getVnSelect).type('{downArrow}{enter}');
|
||||||
|
cy.get('button[title="Save"]').click();
|
||||||
|
cy.get('.q-notification__message').should('have.text', 'Data created');
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue