feat: Add e2e user invite test suite (no-changelog) (#5412)

This commit is contained in:
Alex Grozav
2023-02-08 22:41:35 +02:00
committed by GitHub
parent 9c1f827dad
commit e059caf993
14 changed files with 227 additions and 35 deletions

View File

@@ -43,7 +43,7 @@
</template>
<template #footer v-if="showUserArea">
<div :class="$style.userArea">
<div class="ml-3xs">
<div class="ml-3xs" data-test-id="main-sidebar-user-menu">
<!-- This dropdown is only enabled when sidebar is collapsed -->
<el-dropdown
:disabled="!isCollapsed"
@@ -60,12 +60,12 @@
</div>
<template #dropdown>
<el-dropdown-menu>
<el-dropdown-item command="settings">{{
$locale.baseText('settings')
}}</el-dropdown-item>
<el-dropdown-item command="logout">{{
$locale.baseText('auth.signout')
}}</el-dropdown-item>
<el-dropdown-item command="settings">
{{ $locale.baseText('settings') }}
</el-dropdown-item>
<el-dropdown-item command="logout">
{{ $locale.baseText('auth.signout') }}
</el-dropdown-item>
</el-dropdown-menu>
</template>
</el-dropdown>
@@ -337,14 +337,8 @@ export default mixins(
break;
}
},
async onLogout() {
try {
await this.usersStore.logout();
const route = this.$router.resolve({ name: VIEWS.SIGNIN });
window.open(route.href, '_self');
} catch (e) {
this.$showError(e, this.$locale.baseText('auth.signout.error'));
}
onLogout() {
this.$router.push({ name: VIEWS.SIGNOUT });
},
toggleCollapse() {
this.uiStore.toggleSidebarMenuCollapse();