Snackbar fixes
This commit is contained in:
parent
97c840ece7
commit
55ccc74402
|
@ -17,7 +17,7 @@ export default class App {
|
||||||
}
|
}
|
||||||
showError(message) {
|
showError(message) {
|
||||||
if (this.snackbar)
|
if (this.snackbar)
|
||||||
this.snackbar.showError({message: `Error: ${message}`});
|
this.snackbar.showError({message: message});
|
||||||
}
|
}
|
||||||
pushLoader() {
|
pushLoader() {
|
||||||
this.loaderStatus++;
|
this.loaderStatus++;
|
||||||
|
|
|
@ -62,6 +62,7 @@ export default {
|
||||||
activeCheckboxLabel: `vn-check[label="Active"] > label`,
|
activeCheckboxLabel: `vn-check[label="Active"] > label`,
|
||||||
frozenCheckboxLabel: `vn-check[label="Frozen"] > label`,
|
frozenCheckboxLabel: `vn-check[label="Frozen"] > label`,
|
||||||
invoiceByAddressCheckboxInput: `vn-check[label='Invoice by address'] > label > input`,
|
invoiceByAddressCheckboxInput: `vn-check[label='Invoice by address'] > label > input`,
|
||||||
|
verifiedDataCheckbox: `vn-check[label="Verified data"] > label`,
|
||||||
verifiedDataCheckboxInput: `vn-check[label="Verified data"] > label > input`,
|
verifiedDataCheckboxInput: `vn-check[label="Verified data"] > label > input`,
|
||||||
hasToInvoiceCheckboxLabel: `vn-check[label='Has to invoice'] > label`,
|
hasToInvoiceCheckboxLabel: `vn-check[label='Has to invoice'] > label`,
|
||||||
invoiceByMailCheckboxLabel: `vn-check[label='Invoice by mail'] > label`,
|
invoiceByMailCheckboxLabel: `vn-check[label='Invoice by mail'] > label`,
|
||||||
|
|
|
@ -58,7 +58,7 @@ describe('Client', () => {
|
||||||
.waitToClick(selectors.clientPayMethod.saveButton)
|
.waitToClick(selectors.clientPayMethod.saveButton)
|
||||||
.waitForSnackbar()
|
.waitForSnackbar()
|
||||||
.then(result => {
|
.then(result => {
|
||||||
expect(result).toContain('Error');
|
expect(result).toContain('requires an IBAN');
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -143,7 +143,7 @@ describe('Client', () => {
|
||||||
.waitToClick(selectors.clientAddresses.saveButton)
|
.waitToClick(selectors.clientAddresses.saveButton)
|
||||||
.waitForSnackbar()
|
.waitForSnackbar()
|
||||||
.then(result => {
|
.then(result => {
|
||||||
expect(result).toContain('Error:');
|
expect(result).toContain('The default consignee can not be unchecked');
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
|
@ -63,7 +63,7 @@ describe('Client', () => {
|
||||||
.evaluate(selector => {
|
.evaluate(selector => {
|
||||||
console.log(document.querySelector(selector));
|
console.log(document.querySelector(selector));
|
||||||
return document.querySelector(selector).className;
|
return document.querySelector(selector).className;
|
||||||
}, 'vn-client-fiscal-data > form > vn-card > div > vn-horizontal:nth-child(5) > vn-check:nth-child(4) > label')
|
}, selectors.clientFiscalData.verifiedDataCheckbox)
|
||||||
.then(result => {
|
.then(result => {
|
||||||
expect(result).toContain('is-disabled');
|
expect(result).toContain('is-disabled');
|
||||||
});
|
});
|
||||||
|
@ -152,7 +152,7 @@ describe('Client', () => {
|
||||||
.wait(selectors.clientFiscalData.verifiedDataCheckboxInput)
|
.wait(selectors.clientFiscalData.verifiedDataCheckboxInput)
|
||||||
.evaluate(selector => {
|
.evaluate(selector => {
|
||||||
return document.querySelector(selector).className;
|
return document.querySelector(selector).className;
|
||||||
}, 'vn-client-fiscal-data > form > vn-card > div > vn-horizontal:nth-child(5) > vn-check:nth-child(3) > label')
|
}, selectors.clientFiscalData.verifiedDataCheckbox)
|
||||||
.then(result => {
|
.then(result => {
|
||||||
expect(result).not.toContain('is-disabled');
|
expect(result).not.toContain('is-disabled');
|
||||||
});
|
});
|
||||||
|
@ -265,7 +265,7 @@ describe('Client', () => {
|
||||||
.wait(selectors.clientFiscalData.verifiedDataCheckboxInput)
|
.wait(selectors.clientFiscalData.verifiedDataCheckboxInput)
|
||||||
.evaluate(selector => {
|
.evaluate(selector => {
|
||||||
return document.querySelector(selector).className;
|
return document.querySelector(selector).className;
|
||||||
}, 'vn-client-fiscal-data > form > vn-card > div > vn-horizontal:nth-child(5) > vn-check:nth-child(3) > label')
|
}, selectors.clientFiscalData.verifiedDataCheckbox)
|
||||||
.then(result => {
|
.then(result => {
|
||||||
expect(result).toContain('is-disabled');
|
expect(result).toContain('is-disabled');
|
||||||
});
|
});
|
||||||
|
@ -341,7 +341,7 @@ describe('Client', () => {
|
||||||
.wait(selectors.clientFiscalData.verifiedDataCheckboxInput)
|
.wait(selectors.clientFiscalData.verifiedDataCheckboxInput)
|
||||||
.evaluate(selector => {
|
.evaluate(selector => {
|
||||||
return document.querySelector(selector).className;
|
return document.querySelector(selector).className;
|
||||||
}, 'vn-client-fiscal-data > form > vn-card > div > vn-horizontal:nth-child(5) > vn-check:nth-child(3) > label')
|
}, selectors.clientFiscalData.verifiedDataCheckbox)
|
||||||
.then(result => {
|
.then(result => {
|
||||||
expect(result).not.toContain('is-disabled');
|
expect(result).not.toContain('is-disabled');
|
||||||
});
|
});
|
||||||
|
@ -454,7 +454,7 @@ describe('Client', () => {
|
||||||
.wait(selectors.clientFiscalData.verifiedDataCheckboxInput)
|
.wait(selectors.clientFiscalData.verifiedDataCheckboxInput)
|
||||||
.evaluate(selector => {
|
.evaluate(selector => {
|
||||||
return document.querySelector(selector).className;
|
return document.querySelector(selector).className;
|
||||||
}, 'vn-client-fiscal-data > form > vn-card > div > vn-horizontal:nth-child(5) > vn-check:nth-child(4) > label')
|
}, selectors.clientFiscalData.verifiedDataCheckbox)
|
||||||
.then(result => {
|
.then(result => {
|
||||||
expect(result).toContain('is-disabled');
|
expect(result).toContain('is-disabled');
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue