@webpresso/agent-config 0.3.1 → 0.3.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { expect, test } from "@playwright/test";
|
|
2
|
+
const scaffoldHtml = `<!doctype html>
|
|
3
|
+
<html lang="en">
|
|
4
|
+
<head>
|
|
5
|
+
<meta charset="utf-8" />
|
|
6
|
+
<title>Agent Kit smoke page</title>
|
|
7
|
+
</head>
|
|
8
|
+
<body>
|
|
9
|
+
<main>
|
|
10
|
+
<h1>Agent Kit quality scaffold</h1>
|
|
11
|
+
<p data-testid="status">ready</p>
|
|
12
|
+
</main>
|
|
13
|
+
</body>
|
|
14
|
+
</html>`;
|
|
15
|
+
test("checks the package-owned quality scaffold smoke page", async () => {
|
|
16
|
+
expect(scaffoldHtml).toContain("Agent Kit quality scaffold");
|
|
17
|
+
expect(scaffoldHtml).toContain('data-testid="status"');
|
|
18
|
+
expect(scaffoldHtml).toContain("ready");
|
|
19
|
+
});
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { type PlaywrightTestConfig } from "@playwright/test";
|
|
2
|
+
export declare const qualityScaffoldTestDir: string;
|
|
3
|
+
export type QualityScaffoldConfigOverrides = Omit<PlaywrightTestConfig, "testDir"> & {
|
|
4
|
+
/** Override only for advanced migrations; default points at the package-owned scaffold tests. */
|
|
5
|
+
testDir?: string;
|
|
6
|
+
};
|
|
7
|
+
export declare function createQualityScaffoldConfig(overrides?: QualityScaffoldConfigOverrides): PlaywrightTestConfig;
|
|
8
|
+
export default createQualityScaffoldConfig;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { defineConfig } from "@playwright/test";
|
|
2
|
+
import { dirname, join } from "node:path";
|
|
3
|
+
import { fileURLToPath } from "node:url";
|
|
4
|
+
const moduleDir = dirname(fileURLToPath(import.meta.url));
|
|
5
|
+
export const qualityScaffoldTestDir = join(moduleDir, "quality-scaffold");
|
|
6
|
+
const defaultQualityScaffoldConfig = {
|
|
7
|
+
testDir: qualityScaffoldTestDir,
|
|
8
|
+
fullyParallel: true,
|
|
9
|
+
reporter: [["list"]],
|
|
10
|
+
use: {
|
|
11
|
+
trace: "retain-on-failure",
|
|
12
|
+
},
|
|
13
|
+
};
|
|
14
|
+
export function createQualityScaffoldConfig(overrides = {}) {
|
|
15
|
+
const { use: overrideUse, ...restOverrides } = overrides;
|
|
16
|
+
return defineConfig({
|
|
17
|
+
...defaultQualityScaffoldConfig,
|
|
18
|
+
...restOverrides,
|
|
19
|
+
use: {
|
|
20
|
+
...defaultQualityScaffoldConfig.use,
|
|
21
|
+
...overrideUse,
|
|
22
|
+
},
|
|
23
|
+
});
|
|
24
|
+
}
|
|
25
|
+
export default createQualityScaffoldConfig;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@webpresso/agent-config",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.3",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Shared vitest, tsconfig, stryker, and workers-test config for webpresso consumers. Binary-free — pure test/config tooling.",
|
|
6
6
|
"homepage": "https://github.com/webpresso/agent-kit#readme",
|
|
@@ -40,6 +40,12 @@
|
|
|
40
40
|
"default": "./dist/esm/e2e/index.js"
|
|
41
41
|
}
|
|
42
42
|
},
|
|
43
|
+
"./playwright/quality-scaffold": {
|
|
44
|
+
"import": {
|
|
45
|
+
"types": "./dist/esm/playwright/quality-scaffold.d.ts",
|
|
46
|
+
"default": "./dist/esm/playwright/quality-scaffold.js"
|
|
47
|
+
}
|
|
48
|
+
},
|
|
43
49
|
"./process": {
|
|
44
50
|
"import": {
|
|
45
51
|
"types": "./dist/esm/process/index.d.ts",
|
|
@@ -60,33 +66,33 @@
|
|
|
60
66
|
},
|
|
61
67
|
"./tsconfig/base.json": {
|
|
62
68
|
"import": {
|
|
63
|
-
"types": "./dist/esm/tsconfig/base.json",
|
|
64
69
|
"default": "./dist/esm/tsconfig/base.json"
|
|
65
|
-
}
|
|
70
|
+
},
|
|
71
|
+
"default": "./dist/esm/tsconfig/base.json"
|
|
66
72
|
},
|
|
67
73
|
"./tsconfig/cloudflare.json": {
|
|
68
74
|
"import": {
|
|
69
|
-
"types": "./dist/esm/tsconfig/cloudflare.json",
|
|
70
75
|
"default": "./dist/esm/tsconfig/cloudflare.json"
|
|
71
|
-
}
|
|
76
|
+
},
|
|
77
|
+
"default": "./dist/esm/tsconfig/cloudflare.json"
|
|
72
78
|
},
|
|
73
79
|
"./tsconfig/library.json": {
|
|
74
80
|
"import": {
|
|
75
|
-
"types": "./dist/esm/tsconfig/library.json",
|
|
76
81
|
"default": "./dist/esm/tsconfig/library.json"
|
|
77
|
-
}
|
|
82
|
+
},
|
|
83
|
+
"default": "./dist/esm/tsconfig/library.json"
|
|
78
84
|
},
|
|
79
85
|
"./tsconfig/react-library.json": {
|
|
80
86
|
"import": {
|
|
81
|
-
"types": "./dist/esm/tsconfig/react-library.json",
|
|
82
87
|
"default": "./dist/esm/tsconfig/react-library.json"
|
|
83
|
-
}
|
|
88
|
+
},
|
|
89
|
+
"default": "./dist/esm/tsconfig/react-library.json"
|
|
84
90
|
},
|
|
85
91
|
"./tsconfig/react-router.json": {
|
|
86
92
|
"import": {
|
|
87
|
-
"types": "./dist/esm/tsconfig/react-router.json",
|
|
88
93
|
"default": "./dist/esm/tsconfig/react-router.json"
|
|
89
|
-
}
|
|
94
|
+
},
|
|
95
|
+
"default": "./dist/esm/tsconfig/react-router.json"
|
|
90
96
|
},
|
|
91
97
|
"./vitest/flakiness-reporter": {
|
|
92
98
|
"import": {
|
|
@@ -148,15 +154,15 @@
|
|
|
148
154
|
"registry": "https://registry.npmjs.org/"
|
|
149
155
|
},
|
|
150
156
|
"scripts": {
|
|
151
|
-
"build": "tshy",
|
|
157
|
+
"build": "tshy && bun scripts/normalize-tsconfig-json-exports.ts",
|
|
152
158
|
"prepublishOnly": "vp run build",
|
|
153
159
|
"typecheck": "tsc --noEmit",
|
|
154
160
|
"lint:pkg": "publint && attw --pack . --profile esm-only"
|
|
155
161
|
},
|
|
156
162
|
"dependencies": {
|
|
157
163
|
"@vitejs/plugin-react": "^6.0.3",
|
|
158
|
-
"@webpresso/agent-core": "0.1.
|
|
159
|
-
"vite": "^8.1.
|
|
164
|
+
"@webpresso/agent-core": "0.1.2",
|
|
165
|
+
"vite": "^8.1.1",
|
|
160
166
|
"vite-plus": "^0.2.1",
|
|
161
167
|
"vitest": "^4.1.9"
|
|
162
168
|
},
|
|
@@ -204,6 +210,7 @@
|
|
|
204
210
|
"./deploy": "./src/deploy/index.ts",
|
|
205
211
|
"./dev": "./src/dev/index.ts",
|
|
206
212
|
"./e2e": "./src/e2e/index.ts",
|
|
213
|
+
"./playwright/quality-scaffold": "./src/playwright/quality-scaffold.ts",
|
|
207
214
|
"./process": "./src/process/index.ts",
|
|
208
215
|
"./repo-root": "./src/repo-root/index.ts",
|
|
209
216
|
"./stryker": "./src/stryker/index.ts",
|