mirror of
https://github.com/coder/coder.git
synced 2026-06-02 20:48:20 +00:00
d434181941
* feat: add cohesive e2e tests for the web terminal, apps, and workspaces * Fix web terminal flake
19 lines
729 B
TypeScript
19 lines
729 B
TypeScript
import { test, expect } from "@playwright/test"
|
|
import * as constants from "./constants"
|
|
import { STORAGE_STATE } from "./playwright.config"
|
|
import { Language } from "../src/components/CreateUserForm/CreateUserForm"
|
|
|
|
test("create first user", async ({ page }) => {
|
|
await page.goto("/", { waitUntil: "networkidle" })
|
|
|
|
await page.getByLabel(Language.usernameLabel).fill(constants.username)
|
|
await page.getByLabel(Language.emailLabel).fill(constants.email)
|
|
await page.getByLabel(Language.passwordLabel).fill(constants.password)
|
|
await page.getByTestId("trial").click()
|
|
await page.getByTestId("create").click()
|
|
|
|
await expect(page).toHaveURL("/workspaces")
|
|
|
|
await page.context().storageState({ path: STORAGE_STATE })
|
|
})
|