forked from verdnatura/salix-front
Compare commits
4 Commits
dev
...
6943_custo
Author | SHA1 | Date |
---|---|---|
Javier Segarra | 2d8789312b | |
Javier Segarra | d25cdbf34e | |
Javier Segarra | 0ba577ad04 | |
Javier Segarra | f4a7e20c57 |
|
@ -8,6 +8,6 @@ describe('Client balance', () => {
|
|||
});
|
||||
});
|
||||
it('Should load layout', () => {
|
||||
cy.get('.q-card').should('be.visible');
|
||||
cy.get('.q-page').should('be.visible');
|
||||
});
|
||||
});
|
||||
|
|
|
@ -8,6 +8,6 @@ describe('Client credits', () => {
|
|||
});
|
||||
});
|
||||
it('Should load layout', () => {
|
||||
cy.get('.q-card').should('be.visible');
|
||||
cy.get('.q-page').should('be.visible');
|
||||
});
|
||||
});
|
||||
|
|
|
@ -43,21 +43,4 @@ describe('Client list', () => {
|
|||
cy.url().should('include', `/customer/${id}/summary`);
|
||||
});
|
||||
});
|
||||
|
||||
it('Client founded create ticket', () => {
|
||||
const search = 'Jessica Jones';
|
||||
cy.searchByLabel('Name', search);
|
||||
cy.clickButtonsDescriptor(2);
|
||||
cy.waitForElement('#formModel');
|
||||
cy.waitForElement('.q-form');
|
||||
cy.checkValueForm(1, search);
|
||||
});
|
||||
it('Client founded create order', () => {
|
||||
const search = 'Jessica Jones';
|
||||
cy.searchByLabel('Name', search);
|
||||
cy.clickButtonsDescriptor(4);
|
||||
cy.waitForElement('#formModel');
|
||||
cy.waitForElement('.q-form');
|
||||
cy.checkValueForm(2, search);
|
||||
});
|
||||
});
|
||||
|
|
|
@ -8,6 +8,6 @@ describe('Client recoveries', () => {
|
|||
});
|
||||
});
|
||||
it('Should load layout', () => {
|
||||
cy.get('.q-card').should('be.visible');
|
||||
cy.get('.q-page').should('be.visible');
|
||||
});
|
||||
});
|
||||
|
|
|
@ -8,6 +8,6 @@ describe('Client credit opinion', () => {
|
|||
});
|
||||
});
|
||||
it('Should load layout', () => {
|
||||
cy.get('.q-card').should('be.visible');
|
||||
cy.get('.q-page').should('be.visible');
|
||||
});
|
||||
});
|
||||
|
|
|
@ -8,6 +8,6 @@ describe('Client consumption', () => {
|
|||
});
|
||||
});
|
||||
it('Should load layout', () => {
|
||||
cy.get('.q-card').should('be.visible');
|
||||
cy.get('.q-page').should('be.visible');
|
||||
});
|
||||
});
|
||||
|
|
|
@ -8,6 +8,6 @@ describe('Client mandates', () => {
|
|||
});
|
||||
});
|
||||
it('Should load layout', () => {
|
||||
cy.get('.q-card').should('be.visible');
|
||||
cy.get('.q-page').should('be.visible');
|
||||
});
|
||||
});
|
||||
|
|
|
@ -8,6 +8,6 @@ describe('Client samples', () => {
|
|||
});
|
||||
});
|
||||
it('Should load layout', () => {
|
||||
cy.get('.q-card').should('be.visible');
|
||||
cy.get('.q-page').should('be.visible');
|
||||
});
|
||||
});
|
||||
|
|
|
@ -3,11 +3,11 @@ describe('Client web payments', () => {
|
|||
beforeEach(() => {
|
||||
cy.viewport(1280, 720);
|
||||
cy.login('developer');
|
||||
cy.visit('#/customer/1101/others/web-payments', {
|
||||
cy.visit('#/customer/1101/others/web-payment', {
|
||||
timeout: 5000,
|
||||
});
|
||||
});
|
||||
it('Should load layout', () => {
|
||||
cy.get('.q-card').should('be.visible');
|
||||
cy.get('.q-page').should('be.visible');
|
||||
});
|
||||
});
|
||||
|
|
|
@ -245,6 +245,13 @@ Cypress.Commands.add('validateContent', (selector, expectedValue) => {
|
|||
cy.get(selector).should('have.text', expectedValue);
|
||||
});
|
||||
|
||||
Cypress.Commands.add('openActionDescriptor', (opt) => {
|
||||
cy.openActionsDescriptor();
|
||||
const listItem = '[role="menu"] .q-list .q-item';
|
||||
cy.contains(listItem, opt).click();
|
||||
1;
|
||||
});
|
||||
|
||||
Cypress.Commands.add('openActionsDescriptor', () => {
|
||||
cy.get('.header > :nth-child(3) > .q-btn__content > .q-icon').click();
|
||||
});
|
||||
|
@ -254,3 +261,20 @@ Cypress.Commands.add('openUserPanel', () => {
|
|||
'.column > .q-avatar > .q-avatar__content > .q-img > .q-img__container > .q-img__image'
|
||||
).click();
|
||||
});
|
||||
|
||||
Cypress.Commands.add('openActions', (row) => {
|
||||
cy.get('tbody > tr').eq(row).find('.actions > .q-btn').click();
|
||||
});
|
||||
|
||||
Cypress.Commands.add('checkNotification', (type) => {
|
||||
const values = {
|
||||
created: 'Data created',
|
||||
updated: 'Data saved',
|
||||
deleted: 'Data deleted',
|
||||
};
|
||||
cy.get('.q-notification__message').should('have.text', values[type]);
|
||||
});
|
||||
|
||||
Cypress.Commands.add('searchByLabel', (label, value) => {
|
||||
cy.get(`[label="${label}"] > .q-field > .q-field__inner`).type(`${value}{enter}`);
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue