e2e toBe -> toContain for message.text
gitea/salix/pipeline/head This commit looks good
Details
gitea/salix/pipeline/head This commit looks good
Details
This commit is contained in:
parent
b8784688b8
commit
95dae0ab1c
|
@ -19,7 +19,7 @@ describe('Login path', async() => {
|
|||
const message = await page.waitForSnackbar();
|
||||
const state = await page.getState();
|
||||
|
||||
expect(message.text).toBe('Invalid login, remember that distinction is made between uppercase and lowercase');
|
||||
expect(message.text).toContain('Invalid login, remember that distinction is made between uppercase and lowercase');
|
||||
expect(state).toBe('login');
|
||||
});
|
||||
|
||||
|
@ -28,7 +28,7 @@ describe('Login path', async() => {
|
|||
const message = await page.waitForSnackbar();
|
||||
const state = await page.getState();
|
||||
|
||||
expect(message.text).toBe('Invalid login, remember that distinction is made between uppercase and lowercase');
|
||||
expect(message.text).toContain('Invalid login, remember that distinction is made between uppercase and lowercase');
|
||||
expect(state).toBe('login');
|
||||
});
|
||||
|
||||
|
@ -37,7 +37,7 @@ describe('Login path', async() => {
|
|||
const message = await page.waitForSnackbar();
|
||||
const state = await page.getState();
|
||||
|
||||
expect(message.text).toBe('Please enter your username');
|
||||
expect(message.text).toContain('Please enter your username');
|
||||
expect(state).toBe('login');
|
||||
});
|
||||
});
|
||||
|
|
|
@ -31,7 +31,7 @@ describe('Client create path', () => {
|
|||
await page.waitToClick(selectors.createClientView.createButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Some fields are invalid');
|
||||
expect(message.text).toContain('Some fields are invalid');
|
||||
});
|
||||
|
||||
it('should receive an error when clicking the create button having name and Business name fields empty', async() => {
|
||||
|
@ -42,7 +42,7 @@ describe('Client create path', () => {
|
|||
await page.waitToClick(selectors.createClientView.createButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Some fields are invalid');
|
||||
expect(message.text).toContain('Some fields are invalid');
|
||||
});
|
||||
|
||||
it(`should create a new province`, async() => {
|
||||
|
@ -53,7 +53,7 @@ describe('Client create path', () => {
|
|||
await page.waitToClick(selectors.createClientView.saveNewProvicenButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('The province has been created');
|
||||
expect(message.text).toContain('The province has been created');
|
||||
});
|
||||
|
||||
it(`should create a new city`, async() => {
|
||||
|
@ -63,7 +63,7 @@ describe('Client create path', () => {
|
|||
await page.waitToClick(selectors.createClientView.saveNewCityButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('The city has been created');
|
||||
expect(message.text).toContain('The city has been created');
|
||||
});
|
||||
|
||||
it(`should create a new post code`, async() => {
|
||||
|
@ -72,7 +72,7 @@ describe('Client create path', () => {
|
|||
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('The postcode has been created. You can save the data now');
|
||||
expect(message.text).toContain('The postcode has been created. You can save the data now');
|
||||
});
|
||||
|
||||
it(`should attempt to create a new user with all it's data but wrong email`, async() => {
|
||||
|
@ -84,7 +84,7 @@ describe('Client create path', () => {
|
|||
await page.waitToClick(selectors.createClientView.createButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Some fields are invalid');
|
||||
expect(message.text).toContain('Some fields are invalid');
|
||||
});
|
||||
|
||||
it(`should attempt to create a new user with all it's data but wrong postal code`, async() => {
|
||||
|
@ -95,7 +95,7 @@ describe('Client create path', () => {
|
|||
await page.waitToClick(selectors.createClientView.createButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe(`The postcode doesn't exist. Please enter a correct one`);
|
||||
expect(message.text).toContain(`The postcode doesn't exist. Please enter a correct one`);
|
||||
});
|
||||
|
||||
it(`should check for autocompleted city, province and country`, async() => {
|
||||
|
@ -119,7 +119,7 @@ describe('Client create path', () => {
|
|||
await page.waitToClick(selectors.createClientView.createButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should click on the Clients button of the top bar menu', async() => {
|
||||
|
|
|
@ -37,7 +37,7 @@ describe('Client Edit basicData path', () => {
|
|||
await page.waitToClick(selectors.clientBasicData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the name have been edited', async() => {
|
||||
|
@ -101,7 +101,7 @@ describe('Client Edit basicData path', () => {
|
|||
await page.waitToClick(selectors.clientBasicData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should now confirm the name have been edited', async() => {
|
||||
|
|
|
@ -83,7 +83,7 @@ describe('Client Edit fiscalData path', () => {
|
|||
await page.waitToClick(selectors.globalItems.acceptButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Invalid Tax number');
|
||||
expect(message.text).toContain('Invalid Tax number');
|
||||
});
|
||||
|
||||
it(`should edit the fiscal this time with a valid fiscal id`, async() => {
|
||||
|
@ -93,14 +93,14 @@ describe('Client Edit fiscalData path', () => {
|
|||
await page.waitToClick(selectors.globalItems.acceptButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should propagate the Equalization tax', async() => {
|
||||
await page.waitToClick(selectors.globalItems.acceptButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Equivalent tax spreaded');
|
||||
expect(message.text).toContain('Equivalent tax spreaded');
|
||||
});
|
||||
|
||||
it('should receive an error if the fiscal id contains A or B at the beginning', async() => {
|
||||
|
@ -110,7 +110,7 @@ describe('Client Edit fiscalData path', () => {
|
|||
await page.waitToClick(selectors.clientFiscalData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Cannot check Equalization Tax in this NIF/CIF');
|
||||
expect(message.text).toContain('Cannot check Equalization Tax in this NIF/CIF');
|
||||
});
|
||||
|
||||
it('should finally edit the fixcal data correctly as VIES isnt checked and fiscal id is valid for EQtax', async() => {
|
||||
|
@ -119,7 +119,7 @@ describe('Client Edit fiscalData path', () => {
|
|||
await page.waitToClick(selectors.clientFiscalData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
// confirm all addresses have now EQtax checked step 1
|
||||
|
@ -155,7 +155,7 @@ describe('Client Edit fiscalData path', () => {
|
|||
await page.waitToClick(selectors.clientFiscalData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should propagate the Equalization tax changes', async() => {
|
||||
|
@ -163,7 +163,7 @@ describe('Client Edit fiscalData path', () => {
|
|||
await page.waitToClick(selectors.globalItems.acceptButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Equivalent tax spreaded');
|
||||
expect(message.text).toContain('Equivalent tax spreaded');
|
||||
});
|
||||
|
||||
it('should confirm its name have been edited', async() => {
|
||||
|
@ -289,7 +289,7 @@ describe('Client Edit fiscalData path', () => {
|
|||
await page.waitToClick(selectors.clientAddresses.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
// confirm invoice by address checkbox gets checked if the EQtax differs between addresses step 3
|
||||
|
|
|
@ -28,7 +28,7 @@ describe('Client Edit billing data path', () => {
|
|||
await page.waitToClick(selectors.clientBillingData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('That payment method requires an IBAN');
|
||||
expect(message.text).toContain('That payment method requires an IBAN');
|
||||
});
|
||||
|
||||
// 2256: Windows (hidden mode): Entity code doesn't get the focus, '9999' is written in entity name.
|
||||
|
@ -65,7 +65,7 @@ describe('Client Edit billing data path', () => {
|
|||
await page.waitToClick(selectors.clientBillingData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Notification sent!');
|
||||
expect(message.text).toContain('Notification sent!');
|
||||
});
|
||||
|
||||
it('should confirm the due day have been edited', async() => {
|
||||
|
|
|
@ -31,7 +31,7 @@ describe('Client Add address path', () => {
|
|||
await page.waitToClick(selectors.clientFiscalData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Some fields are invalid');
|
||||
expect(message.text).toContain('Some fields are invalid');
|
||||
});
|
||||
|
||||
it('should confirm that the city and province are propertly filled', async() => {
|
||||
|
@ -51,7 +51,7 @@ describe('Client Add address path', () => {
|
|||
await page.waitToClick(selectors.clientAddresses.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Incoterms is required for a non UEE member');
|
||||
expect(message.text).toContain('Incoterms is required for a non UEE member');
|
||||
});
|
||||
|
||||
it(`should receive an error after clicking save button as customsAgent is empty`, async() => {
|
||||
|
@ -59,7 +59,7 @@ describe('Client Add address path', () => {
|
|||
await page.waitToClick(selectors.clientAddresses.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Customs agent is required for a non UEE member');
|
||||
expect(message.text).toContain('Customs agent is required for a non UEE member');
|
||||
});
|
||||
|
||||
it(`should create a new custom agent and then save the address`, async() => {
|
||||
|
@ -73,7 +73,7 @@ describe('Client Add address path', () => {
|
|||
await page.waitToClick(selectors.clientAddresses.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should navigate back to the addresses index`, async() => {
|
||||
|
@ -91,7 +91,7 @@ describe('Client Add address path', () => {
|
|||
await page.waitToClick(selectors.clientAddresses.secondMakeDefaultStar);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should confirm the default address is the expected one`, async() => {
|
||||
|
@ -113,7 +113,7 @@ describe('Client Add address path', () => {
|
|||
await page.waitToClick(selectors.clientAddresses.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('The default consignee can not be unchecked');
|
||||
expect(message.text).toContain('The default consignee can not be unchecked');
|
||||
});
|
||||
|
||||
it(`should go back to the addreses section by clicking the cancel button`, async() => {
|
||||
|
|
|
@ -28,7 +28,7 @@ describe('Client add address notes path', () => {
|
|||
await page.waitToClick(selectors.clientAddresses.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Some fields are invalid');
|
||||
expect(message.text).toContain('Some fields are invalid');
|
||||
});
|
||||
|
||||
it('should not save an observation type without description', async() => {
|
||||
|
@ -37,7 +37,7 @@ describe('Client add address notes path', () => {
|
|||
await page.waitToClick(selectors.clientAddresses.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Some fields are invalid');
|
||||
expect(message.text).toContain('Some fields are invalid');
|
||||
});
|
||||
|
||||
it('should create two new observations', async() => {
|
||||
|
@ -48,6 +48,6 @@ describe('Client add address notes path', () => {
|
|||
await page.waitToClick(selectors.clientAddresses.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
});
|
||||
|
|
|
@ -23,7 +23,7 @@ describe('Client Edit web access path', () => {
|
|||
await page.waitToClick(selectors.clientWebAccess.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm web access is now unchecked', async() => {
|
||||
|
|
|
@ -31,7 +31,7 @@ describe('Client Add notes path', () => {
|
|||
await page.waitToClick(selectors.clientNotes.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the note was created', async() => {
|
||||
|
|
|
@ -27,7 +27,7 @@ describe('Client Add credit path', () => {
|
|||
await page.waitToClick(selectors.clientCredit.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the credit was updated', async() => {
|
||||
|
|
|
@ -26,7 +26,7 @@ describe('Client Add greuge path', () => {
|
|||
await page.waitToClick(selectors.clientGreuge.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Some fields are invalid');
|
||||
expect(message.text).toContain('Some fields are invalid');
|
||||
});
|
||||
|
||||
it(`should create a new greuge with all its data`, async() => {
|
||||
|
@ -36,7 +36,7 @@ describe('Client Add greuge path', () => {
|
|||
await page.waitToClick(selectors.clientGreuge.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the greuge was added to the list', async() => {
|
||||
|
|
|
@ -32,7 +32,7 @@ describe('Client lock verified data path', () => {
|
|||
await page.waitToClick(selectors.clientFiscalData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the social name have been edited', async() => {
|
||||
|
@ -64,7 +64,7 @@ describe('Client lock verified data path', () => {
|
|||
await page.waitToClick(selectors.globalItems.acceptButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm Verified data checkbox is checked', async() => {
|
||||
|
@ -81,7 +81,7 @@ describe('Client lock verified data path', () => {
|
|||
await page.waitToClick(selectors.clientFiscalData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should again confirm the social name have been edited', async() => {
|
||||
|
@ -111,7 +111,7 @@ describe('Client lock verified data path', () => {
|
|||
await page.waitToClick(selectors.clientFiscalData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe(`You can't make changes on a client with verified data`);
|
||||
expect(message.text).toContain(`You can't make changes on a client with verified data`);
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -135,7 +135,7 @@ describe('Client lock verified data path', () => {
|
|||
await page.waitToClick(selectors.clientFiscalData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should now confirm the social name have been edited once and for all', async() => {
|
||||
|
|
|
@ -22,7 +22,7 @@ describe('Client log path', () => {
|
|||
await page.waitToClick(selectors.clientBasicData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should navigate to the log section', async() => {
|
||||
|
|
|
@ -20,7 +20,7 @@ describe('Client balance path', () => {
|
|||
await page.autocompleteSearch(selectors.globalItems.userLocalCompany, 'CCs');
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should access to the balance section to check the data shown matches the local settings', async() => {
|
||||
|
@ -35,7 +35,7 @@ describe('Client balance path', () => {
|
|||
await page.clearInput(selectors.globalItems.userConfigThirdAutocomplete);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should click the new payment button', async() => {
|
||||
|
@ -51,7 +51,7 @@ describe('Client balance path', () => {
|
|||
await page.waitToClick(selectors.clientBalance.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should edit the 1st line reference', async() => {
|
||||
|
@ -60,7 +60,7 @@ describe('Client balance path', () => {
|
|||
await page.keyboard.press('Enter');
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should check balance is now 0, the reference was saved and the company is now VNL becouse the user local settings were removed', async() => {
|
||||
|
@ -85,7 +85,7 @@ describe('Client balance path', () => {
|
|||
await page.waitToClick(selectors.clientBalance.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should check balance is now -100', async() => {
|
||||
|
@ -101,7 +101,7 @@ describe('Client balance path', () => {
|
|||
await page.waitToClick(selectors.clientBalance.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should check balance is now 50', async() => {
|
||||
|
|
|
@ -22,7 +22,7 @@ describe('Client DMS', () => {
|
|||
await page.respondToDialog('accept');
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should click on the first document line worker name making the descriptor visible`, async() => {
|
||||
|
|
|
@ -24,7 +24,7 @@ describe('Client contacts', () => {
|
|||
await page.waitToClick(selectors.clientContacts.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should delete de contact', async() => {
|
||||
|
@ -33,6 +33,6 @@ describe('Client contacts', () => {
|
|||
await page.waitToClick(selectors.clientContacts.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
});
|
||||
|
|
|
@ -26,7 +26,7 @@ describe('Worker basic data path', () => {
|
|||
await page.waitToClick(selectors.workerBasicData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should reload the section then check the name was edited', async() => {
|
||||
|
|
|
@ -21,7 +21,7 @@ describe('Worker pbx path', () => {
|
|||
await page.waitToClick(selectors.workerPbx.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Extension format is invalid');
|
||||
expect(message.text).toContain('Extension format is invalid');
|
||||
});
|
||||
|
||||
it('should sucessfully save the changes', async() => {
|
||||
|
@ -30,6 +30,6 @@ describe('Worker pbx path', () => {
|
|||
await page.waitToClick(selectors.workerPbx.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved! User must access web');
|
||||
expect(message.text).toContain('Data saved! User must access web');
|
||||
});
|
||||
});
|
||||
|
|
|
@ -59,7 +59,7 @@ describe('Worker time control path', () => {
|
|||
await page.respondToDialog('accept');
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Entry removed');
|
||||
expect(message.text).toContain('Entry removed');
|
||||
});
|
||||
|
||||
it(`should scan out Hank Pym to leave early`, async() => {
|
||||
|
|
|
@ -38,7 +38,7 @@ describe('Item Edit basic data path', () => {
|
|||
await page.waitToClick(selectors.itemBasicData.submitBasicDataButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should create a new intrastat`, async() => {
|
||||
|
@ -57,7 +57,7 @@ describe('Item Edit basic data path', () => {
|
|||
await page.waitToClick(selectors.itemBasicData.submitBasicDataButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should confirm the item name was edited`, async() => {
|
||||
|
|
|
@ -23,7 +23,7 @@ describe('Item edit tax path', () => {
|
|||
await page.waitToClick(selectors.itemTax.submitTaxButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should confirm the first item tax class was edited`, async() => {
|
||||
|
|
|
@ -26,7 +26,7 @@ describe('Item create tags path', () => {
|
|||
await page.waitToClick(selectors.itemTags.submitItemTagsButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should confirm the fourth row data is the expected one`, async() => {
|
||||
|
|
|
@ -25,7 +25,7 @@ describe('Item create niche path', () => {
|
|||
await page.waitToClick(selectors.itemNiches.submitNichesButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should confirm the first niche is the expected one`, async() => {
|
||||
|
|
|
@ -23,7 +23,7 @@ describe('Item Create botanical path', () => {
|
|||
await page.waitToClick(selectors.itemBotanical.submitBotanicalButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should confirm the botanical for the item was created`, async() => {
|
||||
|
@ -58,7 +58,7 @@ describe('Item Create botanical path', () => {
|
|||
await page.waitToClick(selectors.itemBotanical.submitBotanicalButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should confirm the botanical for the item was edited`, async() => {
|
||||
|
|
|
@ -23,7 +23,7 @@ describe('Item Create barcodes path', () => {
|
|||
await page.waitToClick(selectors.itemBarcodes.submitBarcodesButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should confirm the barcode 5 is created and it is now the third barcode as the first was deleted`, async() => {
|
||||
|
|
|
@ -45,7 +45,7 @@ describe('Item Create/Clone path', () => {
|
|||
await page.waitToClick(selectors.itemCreateView.createButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm Infinity Gauntlet item was created', async() => {
|
||||
|
|
|
@ -20,7 +20,7 @@ describe('Item regularize path', () => {
|
|||
await page.autocompleteSearch(selectors.globalItems.userLocalWarehouse, 'Warehouse Four');
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should check the local settings were saved', async() => {
|
||||
|
@ -51,7 +51,7 @@ describe('Item regularize path', () => {
|
|||
await page.waitToClick(selectors.itemDescriptor.regularizeSaveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should click on the Tickets button of the top bar menu', async() => {
|
||||
|
@ -70,7 +70,7 @@ describe('Item regularize path', () => {
|
|||
await page.clearInput(selectors.globalItems.userConfigFirstAutocomplete);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should search for the ticket with alias missing', async() => {
|
||||
|
@ -114,7 +114,7 @@ describe('Item regularize path', () => {
|
|||
await page.waitToClick(selectors.itemDescriptor.regularizeSaveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should again click on the Tickets button of the top bar menu', async() => {
|
||||
|
|
|
@ -36,7 +36,7 @@ describe('Item index path', () => {
|
|||
await page.waitToClick(selectors.itemsIndex.saveFieldsButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should navigate forth and back to see the images column is still visible', async() => {
|
||||
|
@ -70,7 +70,7 @@ describe('Item index path', () => {
|
|||
await page.waitToClick(selectors.itemsIndex.saveFieldsButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should now navigate forth and back to see the ids column is now visible', async() => {
|
||||
|
|
|
@ -34,7 +34,7 @@ describe('Item log path', () => {
|
|||
await page.waitToClick(selectors.itemCreateView.createButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should return to the items index by clicking the return to items button', async() => {
|
||||
|
|
|
@ -29,7 +29,7 @@ describe('Item descriptor path', () => {
|
|||
await page.waitToClick(selectors.itemBasicData.submitBasicDataButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should reload the section and check the inactive icon is bright', async() => {
|
||||
|
@ -45,6 +45,6 @@ describe('Item descriptor path', () => {
|
|||
await page.waitToClick(selectors.itemBasicData.submitBasicDataButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
});
|
||||
|
|
|
@ -61,7 +61,7 @@ describe('Ticket List sale path', () => {
|
|||
await page.keyboard.press('Enter');
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should update the description of the new sale', async() => {
|
||||
|
@ -70,7 +70,7 @@ describe('Ticket List sale path', () => {
|
|||
await page.keyboard.press('Enter');
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should add a third empty item to the sale list', async() => {
|
||||
|
@ -88,7 +88,7 @@ describe('Ticket List sale path', () => {
|
|||
await page.waitToClick(selectors.globalItems.acceptButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should verify there's only 1 single line remaining`, async() => {
|
||||
|
|
|
@ -41,7 +41,7 @@ describe('Ticket Edit sale path', () => {
|
|||
await page.keyboard.press('Enter');
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should check it's state is libre now`, async() => {
|
||||
|
@ -55,7 +55,7 @@ describe('Ticket Edit sale path', () => {
|
|||
await page.waitToClick(selectors.ticketSales.setOk);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should check it's state is OK now`, async() => {
|
||||
|
@ -125,7 +125,7 @@ describe('Ticket Edit sale path', () => {
|
|||
await page.type(selectors.ticketSales.firstSaleQuantity, '11\u000d');
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('The new quantity should be smaller than the old one');
|
||||
expect(message.text).toContain('The new quantity should be smaller than the old one');
|
||||
});
|
||||
|
||||
it('should remove 1 from the first sale quantity', async() => {
|
||||
|
@ -135,7 +135,7 @@ describe('Ticket Edit sale path', () => {
|
|||
await page.type(selectors.ticketSales.firstSaleQuantity, '9\u000d');
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should update the price', async() => {
|
||||
|
@ -144,7 +144,7 @@ describe('Ticket Edit sale path', () => {
|
|||
await page.type(selectors.ticketSales.firstSalePriceInput, '5\u000d');
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the price have been updated', async() => {
|
||||
|
@ -165,7 +165,7 @@ describe('Ticket Edit sale path', () => {
|
|||
await page.type(selectors.ticketSales.firstSaleDiscountInput, '50\u000d');
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the discount have been updated', async() => {
|
||||
|
@ -224,7 +224,7 @@ describe('Ticket Edit sale path', () => {
|
|||
await page.waitForSpinnerLoad();
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should confirm the third sale was deleted`, async() => {
|
||||
|
@ -307,7 +307,7 @@ describe('Ticket Edit sale path', () => {
|
|||
await page.waitToClick(selectors.ticketSales.moveToNewTicketButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe(`You can't create a ticket for a inactive client`);
|
||||
expect(message.text).toContain(`You can't create a ticket for a inactive client`);
|
||||
|
||||
await page.closePopup();
|
||||
});
|
||||
|
|
|
@ -24,7 +24,7 @@ describe('Ticket Create notes path', () => {
|
|||
await page.waitToClick(selectors.ticketNotes.submitNotesButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the note is the expected one', async() => {
|
||||
|
@ -45,6 +45,6 @@ describe('Ticket Create notes path', () => {
|
|||
await page.waitToClick(selectors.ticketNotes.submitNotesButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
});
|
||||
|
|
|
@ -24,7 +24,7 @@ describe('Ticket Create packages path', () => {
|
|||
await page.waitToClick(selectors.ticketPackages.savePackagesButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Package cannot be blank');
|
||||
expect(message.text).toContain('Package cannot be blank');
|
||||
});
|
||||
|
||||
it(`should delete the first package and receive and error to save a new one with blank quantity`, async() => {
|
||||
|
@ -33,7 +33,7 @@ describe('Ticket Create packages path', () => {
|
|||
await page.waitToClick(selectors.ticketPackages.savePackagesButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Some fields are invalid');
|
||||
expect(message.text).toContain('Some fields are invalid');
|
||||
});
|
||||
|
||||
it(`should confirm the quantity input isn't invalid yet`, async() => {
|
||||
|
@ -51,7 +51,7 @@ describe('Ticket Create packages path', () => {
|
|||
await page.waitToClick(selectors.ticketPackages.savePackagesButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should confirm the first select is the expected one`, async() => {
|
||||
|
|
|
@ -28,7 +28,7 @@ describe('Ticket Create new tracking state path', () => {
|
|||
await page.waitToClick(selectors.createStateView.saveStateButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('State cannot be blank');
|
||||
expect(message.text).toContain('State cannot be blank');
|
||||
});
|
||||
|
||||
it(`should create a new state`, async() => {
|
||||
|
@ -36,7 +36,7 @@ describe('Ticket Create new tracking state path', () => {
|
|||
await page.waitToClick(selectors.createStateView.saveStateButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -59,7 +59,7 @@ describe('Ticket Create new tracking state path', () => {
|
|||
await page.waitToClick(selectors.createStateView.saveStateButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe(`You don't have enough privileges`);
|
||||
expect(message.text).toContain(`You don't have enough privileges`);
|
||||
});
|
||||
|
||||
it(`should make sure the worker gets autocomplete uppon selecting the assigned state`, async() => {
|
||||
|
@ -74,7 +74,7 @@ describe('Ticket Create new tracking state path', () => {
|
|||
await page.waitToClick(selectors.createStateView.saveStateButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
|
@ -33,7 +33,7 @@ describe('Ticket descriptor path', () => {
|
|||
await page.waitToClick(selectors.ticketDescriptor.thursdayButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should again click on the Tickets button of the top bar menu', async() => {
|
||||
|
@ -68,7 +68,7 @@ describe('Ticket descriptor path', () => {
|
|||
await page.waitToClick(selectors.ticketDescriptor.saturdayButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should click on the Tickets button of the top bar menu once again', async() => {
|
||||
|
@ -97,7 +97,7 @@ describe('Ticket descriptor path', () => {
|
|||
await page.waitToClick(selectors.ticketsIndex.acceptDeleteTurn);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the sixth weekly ticket was deleted', async() => {
|
||||
|
@ -111,11 +111,11 @@ describe('Ticket descriptor path', () => {
|
|||
await page.autocompleteSearch(selectors.ticketsIndex.firstWeeklyTicketAgency, 'Silla247');
|
||||
let message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
|
||||
await page.clearInput(selectors.ticketsIndex.firstWeeklyTicketAgency);
|
||||
message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
});
|
||||
|
|
|
@ -27,7 +27,7 @@ describe('Ticket purchase request path', () => {
|
|||
await page.waitToClick(selectors.ticketRequests.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should have been redirected to the request index', async() => {
|
||||
|
@ -39,7 +39,7 @@ describe('Ticket purchase request path', () => {
|
|||
await page.keyboard.press('Enter');
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should check the new request was added', async() => {
|
||||
|
@ -67,7 +67,7 @@ describe('Ticket purchase request path', () => {
|
|||
await page.waitToClick(selectors.ticketRequests.thirdRemoveRequestButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should check the request was deleted', async() => {
|
||||
|
|
|
@ -28,7 +28,7 @@ describe('Ticket descriptor path', () => {
|
|||
await page.waitToClick(selectors.ticketDescriptor.acceptChangeHourButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Shipped hour updated');
|
||||
expect(message.text).toContain('Shipped hour updated');
|
||||
});
|
||||
|
||||
it(`should confirm the ticket descriptor shows the correct shipping hour`, async() => {
|
||||
|
@ -45,7 +45,7 @@ describe('Ticket descriptor path', () => {
|
|||
await page.waitToClick(selectors.ticketDescriptor.acceptDialog);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Ticket deleted. You can undo this action within the first hour');
|
||||
expect(message.text).toContain('Ticket deleted. You can undo this action within the first hour');
|
||||
});
|
||||
|
||||
it('should have been relocated to the ticket index', async() => {
|
||||
|
@ -71,7 +71,7 @@ describe('Ticket descriptor path', () => {
|
|||
await page.waitForState('ticket.card.summary');
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should make sure the ticketDeleted icon is no longer bright', async() => {
|
||||
|
@ -102,7 +102,7 @@ describe('Ticket descriptor path', () => {
|
|||
await page.waitToClick(selectors.ticketDescriptor.addStowawayDialogFirstTicket);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should check the state of the stowaway ticket is embarked`, async() => {
|
||||
|
@ -124,7 +124,7 @@ describe('Ticket descriptor path', () => {
|
|||
await page.waitToClick(selectors.ticketDescriptor.acceptDeleteStowawayButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should confirm the ship buton doesn't exisist any more`, async() => {
|
||||
|
@ -155,7 +155,7 @@ describe('Ticket descriptor path', () => {
|
|||
await page.waitToClick(selectors.ticketDescriptor.acceptInvoiceOutButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Ticket invoiced');
|
||||
expect(message.text).toContain('Ticket invoiced');
|
||||
});
|
||||
|
||||
it(`should make sure the ticket summary have an invoiceOutFk`, async() => {
|
||||
|
|
|
@ -34,7 +34,7 @@ describe('Ticket services path', () => {
|
|||
await page.waitToClick(selectors.ticketService.saveServiceButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe(`The current ticket can't be modified`);
|
||||
expect(message.text).toContain(`The current ticket can't be modified`);
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -58,7 +58,7 @@ describe('Ticket services path', () => {
|
|||
await page.waitToClick(selectors.ticketService.saveServiceButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe(`can't be blank`);
|
||||
expect(message.text).toContain(`can't be blank`);
|
||||
});
|
||||
|
||||
it('should click on the add new service type to open the dialog', async() => {
|
||||
|
@ -73,7 +73,7 @@ describe('Ticket services path', () => {
|
|||
await page.waitToClick(selectors.ticketService.saveServiceTypeButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe(`Name can't be empty`);
|
||||
expect(message.text).toContain(`Name can't be empty`);
|
||||
});
|
||||
|
||||
it('should create a new service type then add price then create the service', async() => {
|
||||
|
@ -83,7 +83,7 @@ describe('Ticket services path', () => {
|
|||
await page.waitToClick(selectors.ticketService.saveServiceButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the service description was created correctly', async() => {
|
||||
|
@ -114,7 +114,7 @@ describe('Ticket services path', () => {
|
|||
await page.waitToClick(selectors.ticketService.saveServiceButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should confirm the service was removed`, async() => {
|
||||
|
|
|
@ -31,7 +31,7 @@ describe('Ticket create path', () => {
|
|||
await page.waitToClick(selectors.createTicketView.createButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should check the url is now the summary of the ticket', async() => {
|
||||
|
@ -55,7 +55,7 @@ describe('Ticket create path', () => {
|
|||
await page.waitToClick(selectors.createTicketView.createButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should check the url is now the summary of the created ticket', async() => {
|
||||
|
@ -68,7 +68,7 @@ describe('Ticket create path', () => {
|
|||
await page.waitToClick(selectors.ticketDescriptor.addStowawayDialogFirstTicket);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should delete the current ticket', async() => {
|
||||
|
@ -77,7 +77,7 @@ describe('Ticket create path', () => {
|
|||
await page.waitToClick(selectors.ticketDescriptor.acceptDialog);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Ticket deleted. You can undo this action within the first hour');
|
||||
expect(message.text).toContain('Ticket deleted. You can undo this action within the first hour');
|
||||
});
|
||||
|
||||
it('should search for the stowaway ticket of the previously deleted ticket', async() => {
|
||||
|
|
|
@ -80,7 +80,7 @@ describe('Ticket Summary path', () => {
|
|||
await page.waitToClick(selectors.ticketSummary.setOk);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the ticket state was updated', async() => {
|
||||
|
|
|
@ -29,7 +29,7 @@ describe('Ticket log path', () => {
|
|||
await page.waitToClick(selectors.ticketNotes.submitNotesButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should navigate to the log section', async() => {
|
||||
|
|
|
@ -26,7 +26,7 @@ describe('Ticket index payout path', () => {
|
|||
await page.waitToClick(selectors.ticketsIndex.payoutButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('You cannot make a payment on account from multiple clients');
|
||||
expect(message.text).toContain('You cannot make a payment on account from multiple clients');
|
||||
});
|
||||
|
||||
it('should uncheck the sixth ticket result and check the third which is from the same client then open the payout form', async() => {
|
||||
|
@ -42,7 +42,7 @@ describe('Ticket index payout path', () => {
|
|||
await page.waitToClick(selectors.ticketsIndex.submitPayout);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should navigate to the client balance section and check a new balance line was entered', async() => {
|
||||
|
|
|
@ -27,7 +27,7 @@ describe('Claim edit basic data path', () => {
|
|||
await page.waitToClick(selectors.claimBasicData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should have been redirected to the next section of claims as the role is claimManager`, async() => {
|
||||
|
@ -40,7 +40,7 @@ describe('Claim edit basic data path', () => {
|
|||
await page.waitToClick(selectors.claimBasicData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the claim state was edited', async() => {
|
||||
|
@ -71,6 +71,6 @@ describe('Claim edit basic data path', () => {
|
|||
await page.waitToClick(selectors.claimBasicData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
});
|
||||
|
|
|
@ -28,7 +28,7 @@ describe('Claim development', () => {
|
|||
await page.waitToClick(selectors.claimDevelopment.saveDevelopmentButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should redirect to the next section of claims as the role is claimManager`, async() => {
|
||||
|
@ -45,7 +45,7 @@ describe('Claim development', () => {
|
|||
await page.waitToClick(selectors.claimDevelopment.saveDevelopmentButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the first development is the expected one', async() => {
|
||||
|
|
|
@ -23,7 +23,7 @@ xdescribe('Claim detail', () => {
|
|||
await page.waitToClick(selectors.claimDetail.firstClaimableSaleFromTicket);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the claim contains now two items', async() => {
|
||||
|
@ -38,7 +38,7 @@ xdescribe('Claim detail', () => {
|
|||
await page.keyboard.press('Enter');
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the first item quantity, and the claimed total were correctly edited', async() => {
|
||||
|
@ -67,7 +67,7 @@ xdescribe('Claim detail', () => {
|
|||
await page.keyboard.press('Enter');
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should check the mana is the expected one', async() => {
|
||||
|
@ -81,7 +81,7 @@ xdescribe('Claim detail', () => {
|
|||
await page.waitToClick(selectors.claimDetail.secondItemDeleteButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the claim contains now one item', async() => {
|
||||
|
@ -95,7 +95,7 @@ xdescribe('Claim detail', () => {
|
|||
await page.waitToClick(selectors.claimDetail.firstClaimableSaleFromTicket);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should have been redirected to the next section in claims`, async() => {
|
||||
|
|
|
@ -21,7 +21,7 @@ describe('Claim action path', () => {
|
|||
await page.waitToClick(selectors.claimAction.importClaimButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should import the second importable ticket', async() => {
|
||||
|
@ -33,7 +33,7 @@ describe('Claim action path', () => {
|
|||
await page.waitToClick(selectors.claimAction.secondImportableTicket);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should edit the second line destination field', async() => {
|
||||
|
@ -41,14 +41,14 @@ describe('Claim action path', () => {
|
|||
await page.autocompleteSearch(selectors.claimAction.secondLineDestination, 'Bueno');
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should delete the first line', async() => {
|
||||
await page.waitToClick(selectors.claimAction.firstDeleteLine);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should refresh the view to check the remaining line is the expected one', async() => {
|
||||
|
@ -62,14 +62,14 @@ describe('Claim action path', () => {
|
|||
await page.waitToClick(selectors.claimAction.firstDeleteLine);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should check the "is paid with mana" checkbox', async() => {
|
||||
await page.waitToClick(selectors.claimAction.isPaidWithManaCheckbox);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the "is paid with mana" is checked', async() => {
|
||||
|
|
|
@ -42,7 +42,7 @@ describe('claim Descriptor path', () => {
|
|||
await page.waitToClick(selectors.claimDescriptor.acceptDeleteClaim);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Claim deleted!');
|
||||
expect(message.text).toContain('Claim deleted!');
|
||||
});
|
||||
|
||||
it(`should have been relocated to the claim index`, async() => {
|
||||
|
|
|
@ -25,7 +25,7 @@ describe('Order edit basic data path', () => {
|
|||
await page.waitToClick(selectors.orderBasicData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe(`You can't make changes on the basic data of an confirmed order or with rows`);
|
||||
expect(message.text).toContain(`You can't make changes on the basic data of an confirmed order or with rows`);
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -47,7 +47,7 @@ describe('Order edit basic data path', () => {
|
|||
await page.waitToClick(selectors.orderBasicData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe(`You can't make changes on the basic data of an confirmed order or with rows`);
|
||||
expect(message.text).toContain(`You can't make changes on the basic data of an confirmed order or with rows`);
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -81,7 +81,7 @@ describe('Order edit basic data path', () => {
|
|||
await page.waitToClick(selectors.orderBasicData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should now confirm the client have been edited', async() => {
|
||||
|
|
|
@ -28,7 +28,7 @@ describe('Order lines', () => {
|
|||
await page.waitToClick(selectors.orderLine.confirmButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the order subtotal has changed', async() => {
|
||||
|
|
|
@ -33,7 +33,7 @@ describe('Route basic Data path', () => {
|
|||
await page.waitToClick(selectors.routeBasicData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the worker was edited', async() => {
|
||||
|
|
|
@ -27,7 +27,7 @@ describe('Route create path', () => {
|
|||
await page.waitToClick(selectors.createRouteView.submitButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Access denied');
|
||||
expect(message.text).toContain('Access denied');
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -51,7 +51,7 @@ describe('Route create path', () => {
|
|||
await page.waitToClick(selectors.createRouteView.submitButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should confirm the redirection to the created route summary`, async() => {
|
||||
|
|
|
@ -23,7 +23,7 @@ xdescribe('Route basic Data path', () => {
|
|||
await page.keyboard.press('Enter');
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the buscamanButton is disabled', async() => {
|
||||
|
@ -60,7 +60,7 @@ xdescribe('Route basic Data path', () => {
|
|||
await page.waitToClick(selectors.routeTickets.confirmButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Ticket removed from route');
|
||||
expect(message.text).toContain('Ticket removed from route');
|
||||
});
|
||||
|
||||
it('should again delete the first ticket in route', async() => {
|
||||
|
@ -68,7 +68,7 @@ xdescribe('Route basic Data path', () => {
|
|||
await page.waitToClick(selectors.routeTickets.confirmButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Ticket removed from route');
|
||||
expect(message.text).toContain('Ticket removed from route');
|
||||
});
|
||||
|
||||
it('should now count how many tickets are in route to find one less', async() => {
|
||||
|
|
|
@ -43,7 +43,7 @@ describe('InvoiceOut descriptor path', () => {
|
|||
await page.waitToClick(selectors.invoiceOutDescriptor.acceptDeleteButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('InvoiceOut deleted');
|
||||
expect(message.text).toContain('InvoiceOut deleted');
|
||||
});
|
||||
|
||||
it('should have been relocated to the invoiceOut index', async() => {
|
||||
|
@ -96,7 +96,7 @@ describe('InvoiceOut descriptor path', () => {
|
|||
await page.waitToClick(selectors.invoiceOutDescriptor.acceptBookingButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('InvoiceOut booked');
|
||||
expect(message.text).toContain('InvoiceOut booked');
|
||||
});
|
||||
|
||||
it(`should check the invoiceOut booked in the summary data`, async() => {
|
||||
|
|
|
@ -51,7 +51,7 @@ describe('Travel thermograph path', () => {
|
|||
const message = await page.waitForSnackbar();
|
||||
const state = await page.getState();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
expect(state).toBe('travel.card.thermograph.index');
|
||||
});
|
||||
|
||||
|
|
|
@ -29,7 +29,7 @@ describe('Travel basic data path', () => {
|
|||
await page.waitToClick(selectors.travelBasicDada.save);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Landing cannot be lesser than shipment');
|
||||
expect(message.text).toContain('Landing cannot be lesser than shipment');
|
||||
});
|
||||
|
||||
it('should undo the changes', async() => {
|
||||
|
@ -37,7 +37,7 @@ describe('Travel basic data path', () => {
|
|||
await page.waitToClick(selectors.travelBasicDada.save);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('No changes to save');
|
||||
expect(message.text).toContain('No changes to save');
|
||||
});
|
||||
|
||||
it('should now edit the whole form then save', async() => {
|
||||
|
@ -52,7 +52,7 @@ describe('Travel basic data path', () => {
|
|||
await page.waitToClick(selectors.travelBasicDada.save);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should reload the section and check the reference was saved', async() => {
|
||||
|
|
|
@ -40,7 +40,7 @@ describe('Zone basic data path', () => {
|
|||
await page.waitToClick(selectors.zoneBasicData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should now reload the section', async() => {
|
||||
|
|
|
@ -35,7 +35,7 @@ describe('Entry basic data path', () => {
|
|||
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should confirm the reference was edited', async() => {
|
||||
|
|
|
@ -27,7 +27,7 @@ describe('Supplier basic data path', () => {
|
|||
await page.waitToClick(selectors.supplierBasicData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should reload the section', async() => {
|
||||
|
|
|
@ -35,7 +35,7 @@ describe('Supplier fiscal data path', () => {
|
|||
await page.waitToClick(selectors.supplierFiscalData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Invalid Tax number');
|
||||
expect(message.text).toContain('Invalid Tax number');
|
||||
});
|
||||
|
||||
it('should save the changes as the tax number is valid this time', async() => {
|
||||
|
@ -45,7 +45,7 @@ describe('Supplier fiscal data path', () => {
|
|||
await page.waitToClick(selectors.supplierFiscalData.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it('should reload the section', async() => {
|
||||
|
|
|
@ -27,7 +27,7 @@ describe('Supplier contact path', () => {
|
|||
await page.waitToClick(selectors.supplierContact.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should reload the section and count the contacts`, async() => {
|
||||
|
@ -77,7 +77,7 @@ describe('Supplier contact path', () => {
|
|||
await page.waitToClick(selectors.supplierContact.saveButton);
|
||||
const message = await page.waitForSnackbar();
|
||||
|
||||
expect(message.text).toBe('Data saved!');
|
||||
expect(message.text).toContain('Data saved!');
|
||||
});
|
||||
|
||||
it(`should reload the section and count the amount of contacts went back to 2`, async() => {
|
||||
|
|
Loading…
Reference in New Issue