mirror of
https://github.com/danog/code-server.git
synced 2024-12-13 01:37:31 +01:00
da4de439e0
This uses the current dev build by default but can be overidden with CODE_SERVER_TEST_ENTRY (for example to test a release or some other version). Each instance has a separate state directory. This should make parallelization work. This also means you are no longer required to specify the password and address yourself (or the extension directory once we add a test extension). `yarn test:e2e` should just work as-is. Lastly, it means the tests are no longer subject to yarn watch randomly restarting.
29 lines
950 B
TypeScript
29 lines
950 B
TypeScript
import { storageState } from "../utils/constants"
|
|
import { describe, test, expect } from "./baseFixture"
|
|
|
|
describe("Open Help > About", () => {
|
|
test.use({
|
|
storageState,
|
|
})
|
|
|
|
test("should see a 'Help' then 'About' button in the Application Menu that opens a dialog", async ({
|
|
codeServerPage,
|
|
}) => {
|
|
// Open using the manu
|
|
// Click [aria-label="Application Menu"] div[role="none"]
|
|
await codeServerPage.page.click('[aria-label="Application Menu"] div[role="none"]')
|
|
|
|
// Click the Help button
|
|
await codeServerPage.page.hover("text=Help")
|
|
await codeServerPage.page.click("text=Help")
|
|
|
|
// Click the About button
|
|
await codeServerPage.page.hover("text=About")
|
|
await codeServerPage.page.click("text=About")
|
|
|
|
// Click div[role="dialog"] >> text=code-server
|
|
const element = await codeServerPage.page.waitForSelector('div[role="dialog"] >> text=code-server')
|
|
expect(element).not.toBeNull()
|
|
})
|
|
})
|