Files
dolibarr/test/acceptance/pageObjects/logoutPage.js
SwikritiT a248921d73 List user feature file using api
Co-authored-by:Yamuna Adhikari<adhikariamuna4444@gmail.com>
2020-10-23 11:06:56 +05:45

35 lines
921 B
JavaScript

module.exports = {
url: function () {
return this.api.launchUrl + 'admin/index.php?mainmenu=home&leftmenu=setup&mesg=setupnotcomplete';
},
commands:
[
{
userOpensProfile: async function () {
await this.useXpath()
.waitForElementVisible('@userProfileDropdown')
.click('@userProfileDropdown')
return this.useCss();
},
userLogsOut: function () {
return this.waitForElementVisible('@logoutButton')
.click('@logoutButton');
}
}
],
elements: {
logoutButton: {
selector: '.pull-right'
},
userProfileDropdown: {
selector: '//div[@id="topmenu-login-dropdown"]',
locateStrategy: 'xpath'
}
}
};