Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

chore: tweak e2e test timeouts#15275

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
aslilac merged 8 commits intomainfromlilac/e2e-timeouts
Oct 30, 2024
Merged
Show file tree
Hide file tree
Changes fromall commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletionssite/e2e/helpers.ts
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -425,7 +425,9 @@ export const startAgentWithCommand = async (
);
});

await page.getByTestId("agent-status-ready").waitFor({ state: "visible" });
await page
.getByTestId("agent-status-ready")
.waitFor({ state: "visible", timeout: 45_000 });
return cp;
};

Expand DownExpand Up@@ -928,7 +930,7 @@ export async function openTerminalWindow(
): Promise<Page> {
// Wait for the web terminal to open in a new tab
const pagePromise = context.waitForEvent("page");
await page.getByTestId("terminal").click();
await page.getByTestId("terminal").click({ timeout: 60_000 });
const terminal = await pagePromise;
await terminal.waitForLoadState("domcontentloaded");

Expand Down
8 changes: 2 additions & 6 deletionssite/e2e/playwright.config.ts
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -65,16 +65,12 @@ export default defineConfig({
testMatch: /.*\.spec\.ts/,
dependencies: ["testsSetup"],
use: { storageState },
timeout:50_000,
timeout:30_000,
},
],
reporter: [["./reporter.ts"]],
use: {
// It'd be very nice to add this, but there are some tests that need
// tweaking to make it work consistently (notably, ones that wait for agent
// stats on the workspace page. The default is like 50 seconds, which is
// way too long and makes it painful to wait for test runs in CI.
// actionTimeout: 5000, // 5 seconds
actionTimeout: 5000,
baseURL: `http://localhost:${coderPort}`,
video: "retain-on-failure",
...(wsEndpoint
Expand Down
4 changes: 3 additions & 1 deletionsite/e2e/tests/app.spec.ts
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -13,6 +13,8 @@ import { beforeCoderTest } from "../hooks";
test.beforeEach(({ page }) => beforeCoderTest(page));

test("app", async ({ context, page }) => {
test.setTimeout(75_000);

const appContent = "Hello World";
const token = randomUUID();
const srv = http
Expand DownExpand Up@@ -56,7 +58,7 @@ test("app", async ({ context, page }) => {

// Wait for the web terminal to open in a new tab
const pagePromise = context.waitForEvent("page");
await page.getByText(appName).click();
await page.getByText(appName).click({ timeout: 60_000 });
const app = await pagePromise;
await app.waitForLoadState("domcontentloaded");
await app.getByText(appContent).isVisible();
Expand Down
2 changes: 1 addition & 1 deletionsite/e2e/tests/outdatedAgent.spec.ts
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -17,7 +17,7 @@ const agentVersion = "v2.12.1";
test.beforeEach(({ page }) => beforeCoderTest(page));

test(`ssh with agent ${agentVersion}`, async ({ page }) => {
test.setTimeout(40_000); // This is a slow test, 20s may not be enough on Mac.
test.setTimeout(60_000);

const token = randomUUID();
const template = await createTemplate(page, {
Expand Down
2 changes: 2 additions & 0 deletionssite/e2e/tests/outdatedCLI.spec.ts
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -17,6 +17,8 @@ const clientVersion = "v2.8.0";
test.beforeEach(({ page }) => beforeCoderTest(page));

test(`ssh with client ${clientVersion}`, async ({ page }) => {
test.setTimeout(60_000);

const token = randomUUID();
const template = await createTemplate(page, {
apply: [
Expand Down
2 changes: 2 additions & 0 deletionssite/e2e/tests/webTerminal.spec.ts
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -12,6 +12,8 @@ import { beforeCoderTest } from "../hooks";
test.beforeEach(({ page }) => beforeCoderTest(page));

test("web terminal", async ({ context, page }) => {
test.setTimeout(75_000);

const token = randomUUID();
const template = await createTemplate(page, {
apply: [
Expand Down
Loading

[8]ページ先頭

©2009-2025 Movatter.jp