Files
Jordan Ritter 8c8c563389 fix(showcase/ms-agent-harness-dotnet): align package manager
Aligned everything to npm to match what the Dockerfile already uses
(`npm ci --legacy-peer-deps`) and the committed `package-lock.json`.
The sibling `ms-agent-dotnet` integration uses the same npm-based
setup, so npm is the established convention.

Changes:
- playwright.config.ts: webServer.command now `npm run dev` (was `pnpm dev`),
  so local E2E works in environments without pnpm installed.
- package.json: removed the redundant top-level `pnpm.overrides` block.
  The equivalent override is already declared under npm's `overrides`
  field, so the pnpm block was dead weight given that npm is canonical.
- package.json: `scripts.dev` now uses `concurrently -k --success first`
  so a crashing .NET agent surfaces during local dev instead of leaving
  Next running headlessly.
2026-05-26 13:36:38 -07:00

43 lines
1.5 KiB
TypeScript

import { defineConfig, devices } from "@playwright/test";
export default defineConfig({
testDir: "./tests/e2e",
fullyParallel: true,
forbidOnly: !!process.env.CI,
// Local default of 1 retry covers the `agent_framework.Agent` concurrency
// flake: the shared Agent instance + single OpenAI HTTP client serialise
// SSE streams under high worker counts, so a handful of cells time out at
// 30s on the first attempt and pass cleanly on retry. CI keeps 2 retries
// as the safer ratchet. The underlying upstream fix is per-request agent
// instantiation; see the D5 sweep doc in Notion.
retries: process.env.CI ? 2 : 1,
// Local default of 4 workers caps the SSE concurrency the python agent has
// to absorb. The reused `agent_framework.Agent` + shared OpenAI HTTP client
// serialise concurrent streams; >4 workers makes 30s test timeouts inevitable
// for a few cells. 4 keeps things parallel without overloading the agent.
workers: process.env.CI ? 1 : 4,
reporter: "html",
use: {
baseURL: process.env.BASE_URL || "http://localhost:3000",
trace: "on-first-retry",
},
projects: [
{
name: "chromium",
use: { ...devices["Desktop Chrome"] },
},
],
webServer: process.env.CI
? undefined
: {
command: "npm run dev",
url: "http://localhost:3000",
reuseExistingServer: true,
env: {
...process.env,
OPENAI_BASE_URL: process.env.OPENAI_BASE_URL || "",
OPENAI_API_KEY: process.env.OPENAI_API_KEY || "",
},
},
});