fix: te2e
gitea/salix/pipeline/head This commit looks good
Details
gitea/salix/pipeline/head This commit looks good
Details
This commit is contained in:
parent
eb7bd3dc59
commit
182fe4a38e
|
@ -835,14 +835,16 @@ export default {
|
||||||
confirmButton: '.vn-confirm.shown button[response="accept"]',
|
confirmButton: '.vn-confirm.shown button[response="accept"]',
|
||||||
},
|
},
|
||||||
routeIndex: {
|
routeIndex: {
|
||||||
anyResult: 'vn-table a',
|
anyResult: 'vn-route-index tbody > tr',
|
||||||
firstRouteCheckbox: 'a:nth-child(1) vn-td:nth-child(1) > vn-check',
|
firstRouteCheckbox: 'vn-route-index tbody > tr:nth-child(1) > td:nth-child(1) > vn-check',
|
||||||
addNewRouteButton: 'vn-route-index a[ui-sref="route.create"]',
|
addNewRouteButton: 'vn-route-index a[ui-sref="route.create"]',
|
||||||
cloneButton: 'vn-route-index button > vn-icon[icon="icon-clone"]',
|
cloneButton: 'vn-route-index button > vn-icon[icon="icon-clone"]',
|
||||||
submitClonationButton: 'tpl-buttons > button[response="accept"]',
|
submitClonationButton: 'tpl-buttons > button[response="accept"]',
|
||||||
openAdvancedSearchButton: 'vn-searchbar .append vn-icon[icon="arrow_drop_down"]',
|
openAdvancedSearchButton: 'vn-searchbar .append vn-icon[icon="arrow_drop_down"]',
|
||||||
searchAgencyAutocomlete: 'vn-route-search-panel vn-autocomplete[ng-model="filter.agencyModeFk"]',
|
searchAgencyAutocomlete: 'vn-route-search-panel vn-autocomplete[ng-model="filter.agencyModeFk"]',
|
||||||
advancedSearchButton: 'vn-route-search-panel button[type=submit]',
|
advancedSearchButton: 'vn-route-search-panel button[type=submit]',
|
||||||
|
previewButton: 'vn-route-index tbody > tr:nth-child(7) > td:nth-child(11) > vn-icon-button[icon="preview"]',
|
||||||
|
|
||||||
},
|
},
|
||||||
createRouteView: {
|
createRouteView: {
|
||||||
worker: 'vn-route-create vn-autocomplete[ng-model="$ctrl.route.workerFk"]',
|
worker: 'vn-route-create vn-autocomplete[ng-model="$ctrl.route.workerFk"]',
|
||||||
|
@ -862,6 +864,8 @@ export default {
|
||||||
firstTicketDescriptor: '.vn-popover.shown vn-ticket-descriptor',
|
firstTicketDescriptor: '.vn-popover.shown vn-ticket-descriptor',
|
||||||
firstAlias: 'vn-route-summary vn-tbody > vn-tr:nth-child(1) > vn-td:nth-child(3) > span',
|
firstAlias: 'vn-route-summary vn-tbody > vn-tr:nth-child(1) > vn-td:nth-child(3) > span',
|
||||||
firstClientDescriptor: '.vn-popover.shown vn-client-descriptor',
|
firstClientDescriptor: '.vn-popover.shown vn-client-descriptor',
|
||||||
|
goToRouteSummaryButton: 'vn-route-summary > vn-card > h5 > a',
|
||||||
|
|
||||||
},
|
},
|
||||||
routeBasicData: {
|
routeBasicData: {
|
||||||
worker: 'vn-route-basic-data vn-autocomplete[ng-model="$ctrl.route.workerFk"]',
|
worker: 'vn-route-basic-data vn-autocomplete[ng-model="$ctrl.route.workerFk"]',
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
import selectors from '../../helpers/selectors.js';
|
import selectors from '../../helpers/selectors.js';
|
||||||
import getBrowser from '../../helpers/puppeteer';
|
import getBrowser from '../../helpers/puppeteer';
|
||||||
|
|
||||||
describe('Route summary path', () => {
|
fdescribe('Route summary path', () => {
|
||||||
let browser;
|
let browser;
|
||||||
let page;
|
let page;
|
||||||
|
|
||||||
|
@ -9,7 +9,8 @@ describe('Route summary path', () => {
|
||||||
browser = await getBrowser();
|
browser = await getBrowser();
|
||||||
page = browser.page;
|
page = browser.page;
|
||||||
await page.loginAndModule('employee', 'route');
|
await page.loginAndModule('employee', 'route');
|
||||||
await page.waitToClick('vn-route-index vn-tbody > a:nth-child(7)');
|
await page.waitToClick(selectors.routeIndex.previewButton);
|
||||||
|
await page.waitToClick(selectors.routeSummary.goToRouteSummaryButton);
|
||||||
});
|
});
|
||||||
|
|
||||||
afterAll(async() => {
|
afterAll(async() => {
|
||||||
|
@ -34,6 +35,7 @@ describe('Route summary path', () => {
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should click on the first ticket ID making the descriptor popover visible', async() => {
|
it('should click on the first ticket ID making the descriptor popover visible', async() => {
|
||||||
|
await page.waitForState('route.card.summary');
|
||||||
await page.waitToClick(selectors.routeSummary.firstTicketID);
|
await page.waitToClick(selectors.routeSummary.firstTicketID);
|
||||||
await page.waitForSelector(selectors.routeSummary.firstTicketDescriptor);
|
await page.waitForSelector(selectors.routeSummary.firstTicketDescriptor);
|
||||||
const visible = await page.isVisible(selectors.routeSummary.firstTicketDescriptor);
|
const visible = await page.isVisible(selectors.routeSummary.firstTicketDescriptor);
|
||||||
|
|
Loading…
Reference in New Issue