forked from verdnatura/salix-front
test: VnLocation
This commit is contained in:
parent
271e33a999
commit
f06723a919
|
@ -36,20 +36,23 @@ describe('VnLocation', () => {
|
|||
});
|
||||
it('Fin by postalCode', () => {
|
||||
const postCode = '46600';
|
||||
const postCodeLabel = '46600, Valencia(Province one), España';
|
||||
const firstOption = '[role="listbox"] .q-item:nth-child(1)';
|
||||
|
||||
cy.get(inputLocation).click();
|
||||
cy.get(inputLocation).clear();
|
||||
cy.get(inputLocation).type(postCode);
|
||||
cy.get(locationOptions).should('have.length.at.least', 2);
|
||||
cy.get(locationOptions)
|
||||
.get(':nth-child(1)')
|
||||
.should('have.length.at.least', 2);
|
||||
cy.get(
|
||||
firstOption.concat(' > .q-item__section > .q-item__label--caption')
|
||||
).should('have.text', postCodeLabel);
|
||||
cy.get(firstOption).click();
|
||||
cy.get('.q-btn-group > .q-btn--standard > .q-btn__content > .q-icon').click();
|
||||
cy.reload();
|
||||
cy.waitForElement('.q-form');
|
||||
cy.get(inputLocation).should(
|
||||
'have.value',
|
||||
'46600 - Valencia(Province one), España'
|
||||
);
|
||||
cy.get(inputLocation).should('have.value', postCodeLabel);
|
||||
});
|
||||
|
||||
it('Create postCode', () => {
|
||||
|
|
Loading…
Reference in New Issue