mirror of
https://github.com/enso-org/enso.git
synced 2024-12-22 07:21:34 +03:00
f0d02de5c8
- Add E2E tests for setup flow - Remove `styled.Checkbox` in favor of `ariaComponents.Checkbox` - Remove `styled.Input` in favor of `ariaComponents.Input` - Remove `styled.Button` in favor of `ariaComponents.Button` - Rename unnecessary `Settings` prefix from components in `Settings/` # Important Notes None
27 lines
1010 B
TypeScript
27 lines
1010 B
TypeScript
/** @file Actions for the third step of the "setup" page. */
|
|
import { TEXT } from '../actions'
|
|
import BaseActions from './BaseActions'
|
|
import SetupTeamPageActions from './SetupTeamPageActions'
|
|
|
|
// ==============================
|
|
// === SetupInvitePageActions ===
|
|
// ==============================
|
|
|
|
/** Actions for the "invite users" step of the "setup" page. */
|
|
export default class SetupInvitePageActions extends BaseActions {
|
|
/** Invite users by email. */
|
|
inviteUsers(emails: string) {
|
|
return this.step(`Invite users '${emails.split(/[ ;,]+/).join("', '")}'`, async (page) => {
|
|
await page.getByLabel(TEXT.inviteEmailFieldLabel).getByRole('textbox').fill(emails)
|
|
await page.getByText(TEXT.inviteSubmit).click()
|
|
}).into(SetupTeamPageActions)
|
|
}
|
|
|
|
/** Continue to the next step without inviting users. */
|
|
skipInvitingUsers() {
|
|
return this.step('Skip inviting users in setup', async (page) => {
|
|
await page.getByText(TEXT.skip).click()
|
|
}).into(SetupTeamPageActions)
|
|
}
|
|
}
|