Skip to content

SWF(refactor): define the Playwright E2E port in one place - #811

Open
devin-ai-integration[bot] wants to merge 1 commit into
mainfrom
devin/1795145883-e2e-port-single-source
Open

devin-ai-integration[bot] wants to merge 1 commit into
mainfrom
devin/1795145883-e2e-port-single-source

Conversation

@devin-ai-integration

@devin-ai-integration devin-ai-integration Bot commented Nov 20, 2026 •

Copy link
Copy Markdown
Contributor

Summary

The E2E port 4322 is now defined only in playwright.config.ts. Before this change, playwright.visual.config.ts hardcoded it a second time. Behavior is unchanged.

// playwright.config.ts
-const e2ePort = 4322;
+export const e2ePort = 4322;

// playwright.visual.config.ts
-import config from './playwright.config';
+import config, { e2ePort } from './playwright.config';
-    command: 'pnpm run build:e2e && pnpm run preview --port 4322',
-    url: 'http://localhost:4322/',
+    command: `pnpm run build:e2e && pnpm run preview --port ${e2ePort}`,

webServer.url now comes from the base config through the existing ...config.webServer spread. After this change, the runtime config has exactly one 4322 literal. The other matches are explanatory examples in docs/ and the historical design and plan docs, which are left as they are.

Evidence (run on this branch)

Test discovery is the same before and after. Running diff -u on the --list output before and after the change gave no differences for either config:

playwright.config.ts         Total: 432 tests in 17 files
playwright.visual.config.ts  Total: 186 tests in 1 file

Default config, real run on port 4322:

$ DEBUG=pw:webserver pnpm exec playwright test tests/e2e/specs/smoke.spec.ts --project=chromium --workers=1
[WebServer] $ astro preview --port 4322
[WebServer] ┃ Local    http://localhost:4322/
pw:webserver HTTP Status: 200
  3 passed (16.3s)

Visual config, real run on port 4322 (command built from e2ePort):

$ DEBUG=pw:webserver pnpm exec playwright test --config=playwright.visual.config.ts --project=chromium --grep ' ホーム(light)$'
[WebServer] $ astro preview --port 4322
[WebServer] ┃ Local    http://localhost:4322/
pw:webserver HTTP Status: 200
  1 passed (6.1s)

pnpm run lint: 0 errors and 0 warnings. There are 2 hints, both about the existing includeIgnoreFile deprecation.

Try it: pnpm exec playwright test --config=playwright.visual.config.ts --list

Not run locally: the full visual suite. Only one visual test was run. CI covers the rest.


Software Factory opened this PR for Daiki
Implemented in session Define E2E port in one place
Review with Devin · Open in Devin Desktop


Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
@devin-ai-integration

Copy link
Copy Markdown
Contributor Author

I'll fix CI failures and address comments from users with write access that start with 'Devin'.

  • Disable automatic comment, CI, and merge conflict monitoring

@coderabbitai

coderabbitai Bot commented Nov 20, 2026

Copy link
Copy Markdown

Important

Review skipped

Bot user detected.

To trigger a single review, invoke the @coderabbitai review command.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 5e10a750-73f2-4df1-aa4b-fbfe0ceffb39

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no bugs or issues to report.

Devin Review

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Nov 20, 2026 •

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
blog 933ef9d Commit Preview URL

Branch Preview URL
Nov 20 2026, 03:42 AM

@devin-ai-integration

Copy link
Copy Markdown
Contributor Author

QA結果: 合格(933ef9d)

E2Eと見た目のテストは、どちらも変わらずポート4322で動きました。

確認 結果
設定の解決値 合格。両方の設定で webServer.url が http://localhost:4322/、コマンドが --port 4322 です。見た目のテストの設定は、消した url を元の設定から引き継いでいます
E2E(chromium) 合格。70件成功、2件スキップ。実行中に 127.0.0.1:4322 で待ち受けていました
見た目のテスト(CIと同じ mcr.microsoft.com/playwright:v1.65.1-noble、Noto CJK あり) 合格。139件成功、47件スキップ。基準画像は更新していません。4322で待ち受けていました
pnpm run lint 合格。エラー0件、警告0件

画面の変更がない設定だけのPRなので、録画とスクリーンショットは付けていません。失敗はありませんでした。
E2Eはchromiumだけで実行し、ほかのブラウザでは確かめていません。

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants