diff --git a/src/pages/Route/RouteList.vue b/src/pages/Route/RouteList.vue
index 14c7cda09..b13e8cacd 100644
--- a/src/pages/Route/RouteList.vue
+++ b/src/pages/Route/RouteList.vue
@@ -272,6 +272,7 @@ const openTicketsDialog = (id) => {
{
+ 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');
+ });
+});
diff --git a/test/cypress/integration/route/routeList.spec.js b/test/cypress/integration/route/routeList.spec.js
index d30595d52..f28bc984d 100644
--- a/test/cypress/integration/route/routeList.spec.js
+++ b/test/cypress/integration/route/routeList.spec.js
@@ -4,12 +4,28 @@ describe('Route', () => {
cy.login('developer');
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', () => {
- cy.visit(`/#/route/list`);
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('.q-notification__message').should('have.text', 'Data created');
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');
+ });
});