diff --git a/src/components/UserMenu.vue b/src/components/UserMenu.vue
index 2f7a9ad519a..f6d1fa2f871 100644
--- a/src/components/UserMenu.vue
+++ b/src/components/UserMenu.vue
@@ -27,7 +27,9 @@
>
-
- Manage your account
+ Manage your account
-
Log out
diff --git a/tests/acceptance/pageObjects/accountPage.js b/tests/acceptance/pageObjects/accountPage.js
index ce697777f18..a837d0c9fcd 100644
--- a/tests/acceptance/pageObjects/accountPage.js
+++ b/tests/acceptance/pageObjects/accountPage.js
@@ -46,15 +46,12 @@ module.exports = {
return this.waitForElementVisible('@logoutButton').click('@logoutButton')
},
isPageVisible: async function() {
- let isVisible = false
- const handle = []
- await this.api.windowHandles(function(result) {
- handle.push(result.value[1])
- })
- await this.api.switchWindow(handle[0])
+ let isVisible = true
+
await this.api.element('@accountDisplay', result => {
isVisible = Object.keys(result.value).length > 0
})
+
return isVisible
}
},
diff --git a/tests/acceptance/pageObjects/profilePage.js b/tests/acceptance/pageObjects/profilePage.js
index d4e02293eff..adfbafe1e53 100644
--- a/tests/acceptance/pageObjects/profilePage.js
+++ b/tests/acceptance/pageObjects/profilePage.js
@@ -2,13 +2,14 @@ module.exports = {
commands: {
getUserProfileName: async function() {
let userInfo
- await this.waitForElementVisible('@profileInfoContainer')
- .waitForElementVisible('@userProfileName')
- .api.element('@userProfileName', result => {
+ await this.waitForElementVisible('@userProfileName').api.element(
+ '@userProfileName',
+ result => {
this.api.elementIdText(result.value.ELEMENT, text => {
userInfo = text.value
})
- })
+ }
+ )
return userInfo
},
browseToManageAccount: function() {
@@ -16,16 +17,11 @@ module.exports = {
}
},
elements: {
- profileInfoContainer: {
- selector: '#account-info-container'
- },
userProfileName: {
- selector: '//div/h3[@class="uk-card-title"]',
- locateStrategy: 'xpath'
+ selector: '.oc-topbar-personal-label'
},
manageAccount: {
- selector: '//div//span[.="Manage your account"]',
- locateStrategy: 'xpath'
+ selector: '#oc-topbar-account-manage'
}
}
}