32 lines
957 B
JavaScript
32 lines
957 B
JavaScript
import selectors from '../../helpers/selectors.js';
|
|
import getBrowser from '../../helpers/puppeteer';
|
|
|
|
describe('Ticket List components path', () => {
|
|
let browser;
|
|
let page;
|
|
|
|
beforeAll(async() => {
|
|
browser = await getBrowser();
|
|
page = browser.page;
|
|
await page.loginAndModule('employee', 'ticket');
|
|
await page.accessToSearchResult('1');
|
|
await page.accessToSection('ticket.card.components');
|
|
});
|
|
|
|
afterAll(async() => {
|
|
await browser.close();
|
|
});
|
|
|
|
it('should confirm the total base is correct', async() => {
|
|
const name = 'Base €';
|
|
const minLength = name.length;
|
|
|
|
await page.waitPropertyLength(selectors.ticketComponents.base, 'innerText', minLength);
|
|
const base = await page.waitToGetProperty(selectors.ticketComponents.base, 'innerText');
|
|
|
|
|
|
expect(base).toContain('Base');
|
|
expect(base.length).toBeGreaterThan(minLength);
|
|
});
|
|
});
|