Add data testing attributes and adapt tests for team account invitations
This commit adds data testing attributes to key elements in the team account invitations features. It also modifies e2e tests to make use of these attributes. Additionally, it introduces minor tweaks to other parts of the system to better facilitate testing, such as adjustments in timeouts and update of some log messages.
This commit is contained in:
@@ -18,7 +18,17 @@ export class TeamAccountsPageObject {
|
||||
async getTeamFromSelector(teamSlug: string) {
|
||||
await this.openAccountsSelector();
|
||||
|
||||
return this.page.locator(`[data-test="account-selector-team-${teamSlug}"]`);
|
||||
return this.page.locator(`[data-test="account-selector-team"][data-value="${teamSlug}"]`);
|
||||
}
|
||||
|
||||
async selectAccount(teamName: string) {
|
||||
await this.page.click(`[data-test="account-selector-team"][data-name="${teamName}"]`);
|
||||
}
|
||||
|
||||
async getTeams() {
|
||||
await this.openAccountsSelector();
|
||||
|
||||
return this.page.locator('[data-test="account-selector-team"]');
|
||||
}
|
||||
|
||||
async goToSettings() {
|
||||
|
||||
Reference in New Issue
Block a user