#1587 e2e client.create Añadir código postal
This commit is contained in:
parent
e158bd5811
commit
82fd9505ea
|
@ -65,6 +65,18 @@ describe('Client create path', () => {
|
|||
expect(result).toEqual('Some fields are invalid');
|
||||
});
|
||||
|
||||
it(`should attempt to create a new user with all it's data but wrong postal code`, async() => {
|
||||
const result = await nightmare
|
||||
.clearInput(selectors.createClientView.email)
|
||||
.write(selectors.createClientView.email, 'CarolDanvers@verdnatura.es')
|
||||
.clearInput(selectors.createClientView.postcode)
|
||||
.write(selectors.createClientView.postcode, '479999')
|
||||
.waitToClick(selectors.createClientView.createButton)
|
||||
.waitForLastSnackbar();
|
||||
|
||||
expect(result).toEqual(`The postcode doesn't exists. Ensure you put the correct format`);
|
||||
});
|
||||
|
||||
it(`should check for autocompleted city, province and country`, async() => {
|
||||
const clientCity = await nightmare
|
||||
.waitToGetProperty(`${selectors.createClientView.city}`, 'value');
|
||||
|
@ -82,8 +94,8 @@ describe('Client create path', () => {
|
|||
|
||||
it(`should create a new user with all correct data`, async() => {
|
||||
const result = await nightmare
|
||||
.clearInput(selectors.createClientView.email)
|
||||
.write(selectors.createClientView.email, 'caroldanvers@verdnatura.es')
|
||||
.clearInput(selectors.createClientView.postcode)
|
||||
.write(selectors.createClientView.postcode, '46000')
|
||||
.waitToClick(selectors.createClientView.createButton)
|
||||
.waitForLastSnackbar();
|
||||
|
||||
|
|
Loading…
Reference in New Issue