@hasna/testers 0.0.30 → 0.0.32
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.
- package/LICENSE +186 -13
- package/dist/cli/index.js +5 -2
- package/dist/mcp/index.js +103 -11
- package/dist/server/index.js +88 -3
- package/package.json +2 -2
- package/dist/db/sessions.d.ts +0 -36
- package/dist/db/sessions.d.ts.map +0 -1
- package/dist/lib/browser-compat.d.ts +0 -14
- package/dist/lib/browser-compat.d.ts.map +0 -1
- package/dist/lib/repo-discovery.d.ts +0 -102
- package/dist/lib/repo-discovery.d.ts.map +0 -1
- package/dist/lib/repo-executor.d.ts +0 -56
- package/dist/lib/repo-executor.d.ts.map +0 -1
package/LICENSE
CHANGED
|
@@ -1,17 +1,190 @@
|
|
|
1
|
-
Apache License
|
|
2
|
-
Version 2.0, January 2004
|
|
3
|
-
http://www.apache.org/licenses/
|
|
1
|
+
Apache License
|
|
2
|
+
Version 2.0, January 2004
|
|
3
|
+
http://www.apache.org/licenses/
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
you may not use this file except in compliance with the License.
|
|
9
|
-
You may obtain a copy of the License at
|
|
7
|
+
1. Definitions.
|
|
10
8
|
|
|
11
|
-
|
|
9
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
10
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
12
11
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
12
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
13
|
+
the copyright owner that is granting the License.
|
|
14
|
+
|
|
15
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
16
|
+
other entities that control, are controlled by, or are under common
|
|
17
|
+
control with that entity. For the purposes of this definition,
|
|
18
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
19
|
+
direction or management of such entity, whether by contract or
|
|
20
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
21
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
22
|
+
|
|
23
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
24
|
+
exercising permissions granted by this License.
|
|
25
|
+
|
|
26
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
27
|
+
including but not limited to software source code, documentation
|
|
28
|
+
source, and configuration files.
|
|
29
|
+
|
|
30
|
+
"Object" form shall mean any form resulting from mechanical
|
|
31
|
+
transformation or translation of a Source form, including but
|
|
32
|
+
not limited to compiled object code, generated documentation,
|
|
33
|
+
and conversions to other media types.
|
|
34
|
+
|
|
35
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
36
|
+
Object form, made available under the License, as indicated by a
|
|
37
|
+
copyright notice that is included in or attached to the work
|
|
38
|
+
(an example is provided in the Appendix below).
|
|
39
|
+
|
|
40
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
41
|
+
form, that is based on (or derived from) the Work and for which the
|
|
42
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
43
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
44
|
+
of this License, Derivative Works shall not include works that remain
|
|
45
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
46
|
+
the Work and Derivative Works thereof.
|
|
47
|
+
|
|
48
|
+
"Contribution" shall mean any work of authorship, including
|
|
49
|
+
the original version of the Work and any modifications or additions
|
|
50
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
51
|
+
submitted to the Licensor for inclusion in the Work by the copyright owner
|
|
52
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
53
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
54
|
+
means any form of electronic, verbal, or written communication sent
|
|
55
|
+
to the Licensor or its representatives, including but not limited to
|
|
56
|
+
communication on electronic mailing lists, source code control systems,
|
|
57
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
58
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
59
|
+
excluding communication that is conspicuously marked or otherwise
|
|
60
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
61
|
+
|
|
62
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
63
|
+
on behalf of whom a Contribution has been received by the Licensor and
|
|
64
|
+
subsequently incorporated within the Work.
|
|
65
|
+
|
|
66
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
67
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
68
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
69
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
70
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
71
|
+
Work and such Derivative Works in Source or Object form.
|
|
72
|
+
|
|
73
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
74
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
75
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
76
|
+
(except as stated in this section) patent license to make, have made,
|
|
77
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
78
|
+
where such license applies only to those patent claims licensable
|
|
79
|
+
by such Contributor that are necessarily infringed by their
|
|
80
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
81
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
82
|
+
institute patent litigation against any entity (including a
|
|
83
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
84
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
85
|
+
or contributory patent infringement, then any patent licenses
|
|
86
|
+
granted to You under this License for that Work shall terminate
|
|
87
|
+
as of the date such litigation is filed.
|
|
88
|
+
|
|
89
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
90
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
91
|
+
modifications, and in Source or Object form, provided that You
|
|
92
|
+
meet the following conditions:
|
|
93
|
+
|
|
94
|
+
(a) You must give any other recipients of the Work or
|
|
95
|
+
Derivative Works a copy of this License; and
|
|
96
|
+
|
|
97
|
+
(b) You must cause any modified files to carry prominent notices
|
|
98
|
+
stating that You changed the files; and
|
|
99
|
+
|
|
100
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
101
|
+
that You distribute, all copyright, patent, trademark, and
|
|
102
|
+
attribution notices from the Source form of the Work,
|
|
103
|
+
excluding those notices that do not pertain to any part of
|
|
104
|
+
the Derivative Works; and
|
|
105
|
+
|
|
106
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
107
|
+
distribution, then any Derivative Works that You distribute must
|
|
108
|
+
include a readable copy of the attribution notices contained
|
|
109
|
+
within such NOTICE file, excluding any notices that do not
|
|
110
|
+
pertain to any part of the Derivative Works, in at least one
|
|
111
|
+
of the following places: within a NOTICE text file distributed
|
|
112
|
+
as part of the Derivative Works; within the Source form or
|
|
113
|
+
documentation, if provided along with the Derivative Works; or,
|
|
114
|
+
within a display generated by the Derivative Works, if and
|
|
115
|
+
wherever such third-party notices normally appear. The contents
|
|
116
|
+
of the NOTICE file are for informational purposes only and
|
|
117
|
+
do not modify the License. You may add Your own attribution
|
|
118
|
+
notices within Derivative Works that You distribute, alongside
|
|
119
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
120
|
+
that such additional attribution notices cannot be construed
|
|
121
|
+
as modifying the License.
|
|
122
|
+
|
|
123
|
+
You may add Your own copyright statement to Your modifications and
|
|
124
|
+
may provide additional or different license terms and conditions
|
|
125
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
126
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
127
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
128
|
+
the conditions stated in this License.
|
|
129
|
+
|
|
130
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
131
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
132
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
133
|
+
this License, without any additional terms or conditions.
|
|
134
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
135
|
+
the terms of any separate license agreement you may have executed
|
|
136
|
+
with Licensor regarding such Contributions.
|
|
137
|
+
|
|
138
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
139
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
140
|
+
except as required for reasonable and customary use in describing the
|
|
141
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
142
|
+
|
|
143
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
144
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
145
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
146
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
147
|
+
implied, including, without limitation, any warranties or conditions
|
|
148
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
149
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
150
|
+
appropriateness of using or redistributing the Work and assume any
|
|
151
|
+
risks associated with Your exercise of permissions under this License.
|
|
152
|
+
|
|
153
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
154
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
155
|
+
unless required by applicable law (such as deliberate and grossly
|
|
156
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
157
|
+
liable to You for damages, including any direct, indirect, special,
|
|
158
|
+
incidental, or consequential damages of any character arising as a
|
|
159
|
+
result of this License or out of the use or inability to use the
|
|
160
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
161
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
162
|
+
other commercial damages or losses), even if such Contributor
|
|
163
|
+
has been advised of the possibility of such damages.
|
|
164
|
+
|
|
165
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
166
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
167
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
168
|
+
or other liability obligations and/or rights consistent with this
|
|
169
|
+
License. However, in accepting such obligations, You may act only
|
|
170
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
171
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
172
|
+
defend, and hold each Contributor harmless for any liability
|
|
173
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
174
|
+
of your accepting any such warranty or additional liability.
|
|
175
|
+
|
|
176
|
+
END OF TERMS AND CONDITIONS
|
|
177
|
+
|
|
178
|
+
Copyright 2026 hasna
|
|
179
|
+
|
|
180
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
181
|
+
you may not use this file except in compliance with the License.
|
|
182
|
+
You may obtain a copy of the License at
|
|
183
|
+
|
|
184
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
185
|
+
|
|
186
|
+
Unless required by applicable law or agreed to in writing, software
|
|
187
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
188
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
189
|
+
See the License for the specific language governing permissions and
|
|
190
|
+
limitations under the License.
|
package/dist/cli/index.js
CHANGED
|
@@ -19121,6 +19121,7 @@ var require_range = __commonJS((exports, module) => {
|
|
|
19121
19121
|
return this.range;
|
|
19122
19122
|
}
|
|
19123
19123
|
parseRange(range) {
|
|
19124
|
+
range = range.replace(BUILDSTRIPRE, "");
|
|
19124
19125
|
const memoOpts = (this.options.includePrerelease && FLAG_INCLUDE_PRERELEASE) | (this.options.loose && FLAG_LOOSE);
|
|
19125
19126
|
const memoKey = memoOpts + ":" + range;
|
|
19126
19127
|
const cached = cache.get(memoKey);
|
|
@@ -19202,12 +19203,14 @@ var require_range = __commonJS((exports, module) => {
|
|
|
19202
19203
|
var SemVer = require_semver();
|
|
19203
19204
|
var {
|
|
19204
19205
|
safeRe: re,
|
|
19206
|
+
src,
|
|
19205
19207
|
t,
|
|
19206
19208
|
comparatorTrimReplace,
|
|
19207
19209
|
tildeTrimReplace,
|
|
19208
19210
|
caretTrimReplace
|
|
19209
19211
|
} = require_re();
|
|
19210
19212
|
var { FLAG_INCLUDE_PRERELEASE, FLAG_LOOSE } = require_constants();
|
|
19213
|
+
var BUILDSTRIPRE = new RegExp(src[t.BUILD], "g");
|
|
19211
19214
|
var isNullSet = (c) => c.value === "<0.0.0-0";
|
|
19212
19215
|
var isAny = (c) => c.value === "";
|
|
19213
19216
|
var isSatisfiable = (comparators, options) => {
|
|
@@ -27842,7 +27845,7 @@ import chalk6 from "chalk";
|
|
|
27842
27845
|
// package.json
|
|
27843
27846
|
var package_default = {
|
|
27844
27847
|
name: "@hasna/testers",
|
|
27845
|
-
version: "0.0.
|
|
27848
|
+
version: "0.0.32",
|
|
27846
27849
|
description: "AI-powered QA testing CLI \u2014 spawns cheap AI agents to test web apps with headless browsers",
|
|
27847
27850
|
type: "module",
|
|
27848
27851
|
main: "dist/index.js",
|
|
@@ -27907,7 +27910,7 @@ var package_default = {
|
|
|
27907
27910
|
},
|
|
27908
27911
|
repository: {
|
|
27909
27912
|
type: "git",
|
|
27910
|
-
url: "https://github.com/hasna/testers.git"
|
|
27913
|
+
url: "git+https://github.com/hasna/testers.git"
|
|
27911
27914
|
},
|
|
27912
27915
|
license: "Apache-2.0",
|
|
27913
27916
|
keywords: [
|
package/dist/mcp/index.js
CHANGED
|
@@ -1312,9 +1312,9 @@ async function syncTransfer(source, target, options, _direction) {
|
|
|
1312
1312
|
const batch = rows.slice(offset, offset + batchSize);
|
|
1313
1313
|
try {
|
|
1314
1314
|
if (isAsyncAdapter(target)) {
|
|
1315
|
-
await batchUpsertPg(target, table, columns, updateCols, pkColumns, batch);
|
|
1315
|
+
await batchUpsertPg(target, table, columns, updateCols, pkColumns, batch, columns.includes(conflictColumn) ? conflictColumn : undefined);
|
|
1316
1316
|
} else {
|
|
1317
|
-
batchUpsertSqlite(target, table, columns, updateCols, pkColumns, batch);
|
|
1317
|
+
batchUpsertSqlite(target, table, columns, updateCols, pkColumns, batch, columns.includes(conflictColumn) ? conflictColumn : undefined);
|
|
1318
1318
|
}
|
|
1319
1319
|
result.rowsWritten += batch.length;
|
|
1320
1320
|
} catch (err) {
|
|
@@ -1361,7 +1361,7 @@ async function syncTransfer(source, target, options, _direction) {
|
|
|
1361
1361
|
}
|
|
1362
1362
|
return results;
|
|
1363
1363
|
}
|
|
1364
|
-
async function batchUpsertPg(target, table, columns, updateCols, primaryKeys, batch) {
|
|
1364
|
+
async function batchUpsertPg(target, table, columns, updateCols, primaryKeys, batch, conflictColumn) {
|
|
1365
1365
|
if (batch.length === 0)
|
|
1366
1366
|
return;
|
|
1367
1367
|
const colList = columns.map((c) => `"${c}"`).join(", ");
|
|
@@ -1371,20 +1371,22 @@ async function batchUpsertPg(target, table, columns, updateCols, primaryKeys, ba
|
|
|
1371
1371
|
}).join(", ");
|
|
1372
1372
|
const pkList = primaryKeys.map((c) => `"${c}"`).join(", ");
|
|
1373
1373
|
const setClause = updateCols.length > 0 ? updateCols.map((c) => `"${c}" = EXCLUDED."${c}"`).join(", ") : `"${primaryKeys[0]}" = EXCLUDED."${primaryKeys[0]}"`;
|
|
1374
|
+
const whereClause = conflictColumn && updateCols.includes(conflictColumn) ? ` WHERE "${table}"."${conflictColumn}" IS NULL OR EXCLUDED."${conflictColumn}" >= "${table}"."${conflictColumn}"` : "";
|
|
1374
1375
|
const sql = `INSERT INTO "${table}" (${colList}) VALUES ${valuePlaceholders}
|
|
1375
|
-
ON CONFLICT (${pkList}) DO UPDATE SET ${setClause}`;
|
|
1376
|
+
ON CONFLICT (${pkList}) DO UPDATE SET ${setClause}${whereClause}`;
|
|
1376
1377
|
const params = batch.flatMap((row) => columns.map((c) => row[c] ?? null));
|
|
1377
1378
|
await target.run(sql, ...params);
|
|
1378
1379
|
}
|
|
1379
|
-
function batchUpsertSqlite(target, table, columns, updateCols, primaryKeys, batch) {
|
|
1380
|
+
function batchUpsertSqlite(target, table, columns, updateCols, primaryKeys, batch, conflictColumn) {
|
|
1380
1381
|
if (batch.length === 0)
|
|
1381
1382
|
return;
|
|
1382
1383
|
const colList = columns.map((c) => `"${c}"`).join(", ");
|
|
1383
1384
|
const valuePlaceholders = batch.map(() => `(${columns.map(() => "?").join(", ")})`).join(", ");
|
|
1384
1385
|
const pkList = primaryKeys.map((c) => `"${c}"`).join(", ");
|
|
1385
1386
|
const setClause = updateCols.length > 0 ? updateCols.map((c) => `"${c}" = EXCLUDED."${c}"`).join(", ") : `"${primaryKeys[0]}" = EXCLUDED."${primaryKeys[0]}"`;
|
|
1387
|
+
const whereClause = conflictColumn && updateCols.includes(conflictColumn) ? ` WHERE "${table}"."${conflictColumn}" IS NULL OR EXCLUDED."${conflictColumn}" >= "${table}"."${conflictColumn}"` : "";
|
|
1386
1388
|
const sql = `INSERT INTO "${table}" (${colList}) VALUES ${valuePlaceholders}
|
|
1387
|
-
ON CONFLICT (${pkList}) DO UPDATE SET ${setClause}`;
|
|
1389
|
+
ON CONFLICT (${pkList}) DO UPDATE SET ${setClause}${whereClause}`;
|
|
1388
1390
|
const params = batch.flatMap((row) => columns.map((c) => coerceForSqlite(row[c])));
|
|
1389
1391
|
target.run(sql, ...params);
|
|
1390
1392
|
}
|
|
@@ -1609,7 +1611,7 @@ class SyncProgressTracker {
|
|
|
1609
1611
|
}
|
|
1610
1612
|
}
|
|
1611
1613
|
}
|
|
1612
|
-
function registerCloudTools(server, serviceName) {
|
|
1614
|
+
function registerCloudTools(server, serviceName, opts = {}) {
|
|
1613
1615
|
server.tool(`${serviceName}_cloud_status`, "Show cloud configuration and connection health", {}, async () => {
|
|
1614
1616
|
const config = getCloudConfig();
|
|
1615
1617
|
const lines = [
|
|
@@ -1642,8 +1644,13 @@ function registerCloudTools(server, serviceName) {
|
|
|
1642
1644
|
isError: true
|
|
1643
1645
|
};
|
|
1644
1646
|
}
|
|
1645
|
-
const local = new SqliteAdapter(getDbPath(serviceName));
|
|
1647
|
+
const local = new SqliteAdapter(opts.dbPath ?? getDbPath(serviceName));
|
|
1646
1648
|
const cloud = new PgAdapterAsync(getConnectionString(serviceName));
|
|
1649
|
+
if (opts.migrations?.length) {
|
|
1650
|
+
for (const sql of opts.migrations) {
|
|
1651
|
+
await cloud.run(sql);
|
|
1652
|
+
}
|
|
1653
|
+
}
|
|
1647
1654
|
const tableList = tablesStr ? tablesStr.split(",").map((t) => t.trim()) : listSqliteTables(local);
|
|
1648
1655
|
const results = await syncPush(local, cloud, { tables: tableList });
|
|
1649
1656
|
local.close();
|
|
@@ -1665,7 +1672,7 @@ function registerCloudTools(server, serviceName) {
|
|
|
1665
1672
|
isError: true
|
|
1666
1673
|
};
|
|
1667
1674
|
}
|
|
1668
|
-
const local = new SqliteAdapter(getDbPath(serviceName));
|
|
1675
|
+
const local = new SqliteAdapter(opts.dbPath ?? getDbPath(serviceName));
|
|
1669
1676
|
const cloud = new PgAdapterAsync(getConnectionString(serviceName));
|
|
1670
1677
|
let tableList;
|
|
1671
1678
|
if (tablesStr) {
|
|
@@ -22261,6 +22268,91 @@ var coerce = {
|
|
|
22261
22268
|
var NEVER = INVALID;
|
|
22262
22269
|
// src/mcp/index.ts
|
|
22263
22270
|
init_dist();
|
|
22271
|
+
// package.json
|
|
22272
|
+
var package_default = {
|
|
22273
|
+
name: "@hasna/testers",
|
|
22274
|
+
version: "0.0.32",
|
|
22275
|
+
description: "AI-powered QA testing CLI \u2014 spawns cheap AI agents to test web apps with headless browsers",
|
|
22276
|
+
type: "module",
|
|
22277
|
+
main: "dist/index.js",
|
|
22278
|
+
types: "dist/index.d.ts",
|
|
22279
|
+
bin: {
|
|
22280
|
+
testers: "dist/cli/index.js",
|
|
22281
|
+
"testers-mcp": "dist/mcp/index.js",
|
|
22282
|
+
"testers-serve": "dist/server/index.js"
|
|
22283
|
+
},
|
|
22284
|
+
exports: {
|
|
22285
|
+
".": {
|
|
22286
|
+
types: "./dist/index.d.ts",
|
|
22287
|
+
import: "./dist/index.js"
|
|
22288
|
+
}
|
|
22289
|
+
},
|
|
22290
|
+
files: [
|
|
22291
|
+
"dist/",
|
|
22292
|
+
"dashboard/dist/",
|
|
22293
|
+
"LICENSE",
|
|
22294
|
+
"README.md"
|
|
22295
|
+
],
|
|
22296
|
+
scripts: {
|
|
22297
|
+
build: "bun run build:dashboard && bun run build:cli && bun run build:mcp && bun run build:server && bun run build:lib && bun run build:types",
|
|
22298
|
+
"build:cli": "bun build src/cli/index.tsx --outdir dist/cli --target bun --external ink --external react --external chalk --external @modelcontextprotocol/sdk --external @anthropic-ai/sdk --external playwright --external @hasna/browser",
|
|
22299
|
+
"build:mcp": "bun build src/mcp/index.ts --outdir dist/mcp --target bun --external @modelcontextprotocol/sdk --external @anthropic-ai/sdk --external playwright --external @hasna/browser",
|
|
22300
|
+
"build:server": "bun build src/server/index.ts --outdir dist/server --target bun --external @anthropic-ai/sdk --external playwright --external @hasna/browser",
|
|
22301
|
+
"build:lib": "bun build src/index.ts --outdir dist --target bun --external playwright --external @anthropic-ai/sdk --external @modelcontextprotocol/sdk --external @hasna/browser",
|
|
22302
|
+
"build:types": "NODE_OPTIONS='--max-old-space-size=8192' tsc --emitDeclarationOnly --outDir dist --skipLibCheck",
|
|
22303
|
+
"build:dashboard": "cd dashboard && bun run build",
|
|
22304
|
+
typecheck: "tsc --noEmit",
|
|
22305
|
+
test: "bun test",
|
|
22306
|
+
"dev:cli": "bun run src/cli/index.tsx",
|
|
22307
|
+
"dev:mcp": "bun run src/mcp/index.ts",
|
|
22308
|
+
"dev:serve": "bun run src/server/index.ts",
|
|
22309
|
+
prepublishOnly: "bun run build",
|
|
22310
|
+
postinstall: "mkdir -p $HOME/.hasna/testers/screenshots $HOME/.hasna/testers/browser/profiles 2>/dev/null || true"
|
|
22311
|
+
},
|
|
22312
|
+
dependencies: {
|
|
22313
|
+
"@anthropic-ai/sdk": "^0.52.0",
|
|
22314
|
+
"@hasna/browser": "^0.3.8",
|
|
22315
|
+
"@hasna/cloud": "^0.1.24",
|
|
22316
|
+
"@hasna/contacts": "^0.6.8",
|
|
22317
|
+
"@modelcontextprotocol/sdk": "^1.12.1",
|
|
22318
|
+
chalk: "^5.4.1",
|
|
22319
|
+
commander: "^13.1.0",
|
|
22320
|
+
ink: "^5.2.0",
|
|
22321
|
+
playwright: "^1.50.0",
|
|
22322
|
+
react: "^18.3.1",
|
|
22323
|
+
zod: "^3.24.2"
|
|
22324
|
+
},
|
|
22325
|
+
devDependencies: {
|
|
22326
|
+
"@types/bun": "latest",
|
|
22327
|
+
"@types/react": "^18.3.18",
|
|
22328
|
+
typescript: "^5.7.3"
|
|
22329
|
+
},
|
|
22330
|
+
engines: {
|
|
22331
|
+
bun: ">=1.0.0"
|
|
22332
|
+
},
|
|
22333
|
+
publishConfig: {
|
|
22334
|
+
registry: "https://registry.npmjs.org",
|
|
22335
|
+
access: "public"
|
|
22336
|
+
},
|
|
22337
|
+
repository: {
|
|
22338
|
+
type: "git",
|
|
22339
|
+
url: "git+https://github.com/hasna/testers.git"
|
|
22340
|
+
},
|
|
22341
|
+
license: "Apache-2.0",
|
|
22342
|
+
keywords: [
|
|
22343
|
+
"testing",
|
|
22344
|
+
"qa",
|
|
22345
|
+
"ai",
|
|
22346
|
+
"playwright",
|
|
22347
|
+
"browser",
|
|
22348
|
+
"screenshot",
|
|
22349
|
+
"automation",
|
|
22350
|
+
"cli",
|
|
22351
|
+
"mcp"
|
|
22352
|
+
]
|
|
22353
|
+
};
|
|
22354
|
+
|
|
22355
|
+
// src/mcp/index.ts
|
|
22264
22356
|
init_scenarios();
|
|
22265
22357
|
|
|
22266
22358
|
// src/lib/templates.ts
|
|
@@ -23643,7 +23735,7 @@ Options:
|
|
|
23643
23735
|
process.exit(0);
|
|
23644
23736
|
}
|
|
23645
23737
|
if (cliArgs.has("--version") || cliArgs.has("-V")) {
|
|
23646
|
-
console.log(
|
|
23738
|
+
console.log(package_default.version);
|
|
23647
23739
|
process.exit(0);
|
|
23648
23740
|
}
|
|
23649
23741
|
function json(data) {
|
|
@@ -23704,7 +23796,7 @@ var ID_DESC = "Accepts either the full UUID (e.g. 'abc123...') or the short ID (
|
|
|
23704
23796
|
var MODEL_DESC = "Model to use. Values: 'quick' (claude-haiku-4-5, cheapest), 'thorough' (claude-sonnet-4-6, balanced), 'deep' (claude-opus-4-6, most capable). Default: 'quick'.";
|
|
23705
23797
|
var server = new McpServer({
|
|
23706
23798
|
name: "testers",
|
|
23707
|
-
version:
|
|
23799
|
+
version: package_default.version
|
|
23708
23800
|
});
|
|
23709
23801
|
server.tool("create_prod_debug_plan", "Create a safe production debug plan for a URL, session ID, project ID, user report, or request ID. Does not use passwords or raw cookies; browser debugging is blocked unless an audited support URL is supplied or an app adapter can resolve a support grant.", {
|
|
23710
23802
|
target: exports_external.string().describe("Production URL, session ID, project ID, request ID, or other target evidence"),
|
package/dist/server/index.js
CHANGED
|
@@ -12569,9 +12569,94 @@ var init_scan_issues = __esm(() => {
|
|
|
12569
12569
|
});
|
|
12570
12570
|
|
|
12571
12571
|
// src/server/index.ts
|
|
12572
|
-
init_paths();
|
|
12573
12572
|
import { existsSync as existsSync10 } from "fs";
|
|
12574
12573
|
import { join as join13 } from "path";
|
|
12574
|
+
// package.json
|
|
12575
|
+
var package_default = {
|
|
12576
|
+
name: "@hasna/testers",
|
|
12577
|
+
version: "0.0.32",
|
|
12578
|
+
description: "AI-powered QA testing CLI \u2014 spawns cheap AI agents to test web apps with headless browsers",
|
|
12579
|
+
type: "module",
|
|
12580
|
+
main: "dist/index.js",
|
|
12581
|
+
types: "dist/index.d.ts",
|
|
12582
|
+
bin: {
|
|
12583
|
+
testers: "dist/cli/index.js",
|
|
12584
|
+
"testers-mcp": "dist/mcp/index.js",
|
|
12585
|
+
"testers-serve": "dist/server/index.js"
|
|
12586
|
+
},
|
|
12587
|
+
exports: {
|
|
12588
|
+
".": {
|
|
12589
|
+
types: "./dist/index.d.ts",
|
|
12590
|
+
import: "./dist/index.js"
|
|
12591
|
+
}
|
|
12592
|
+
},
|
|
12593
|
+
files: [
|
|
12594
|
+
"dist/",
|
|
12595
|
+
"dashboard/dist/",
|
|
12596
|
+
"LICENSE",
|
|
12597
|
+
"README.md"
|
|
12598
|
+
],
|
|
12599
|
+
scripts: {
|
|
12600
|
+
build: "bun run build:dashboard && bun run build:cli && bun run build:mcp && bun run build:server && bun run build:lib && bun run build:types",
|
|
12601
|
+
"build:cli": "bun build src/cli/index.tsx --outdir dist/cli --target bun --external ink --external react --external chalk --external @modelcontextprotocol/sdk --external @anthropic-ai/sdk --external playwright --external @hasna/browser",
|
|
12602
|
+
"build:mcp": "bun build src/mcp/index.ts --outdir dist/mcp --target bun --external @modelcontextprotocol/sdk --external @anthropic-ai/sdk --external playwright --external @hasna/browser",
|
|
12603
|
+
"build:server": "bun build src/server/index.ts --outdir dist/server --target bun --external @anthropic-ai/sdk --external playwright --external @hasna/browser",
|
|
12604
|
+
"build:lib": "bun build src/index.ts --outdir dist --target bun --external playwright --external @anthropic-ai/sdk --external @modelcontextprotocol/sdk --external @hasna/browser",
|
|
12605
|
+
"build:types": "NODE_OPTIONS='--max-old-space-size=8192' tsc --emitDeclarationOnly --outDir dist --skipLibCheck",
|
|
12606
|
+
"build:dashboard": "cd dashboard && bun run build",
|
|
12607
|
+
typecheck: "tsc --noEmit",
|
|
12608
|
+
test: "bun test",
|
|
12609
|
+
"dev:cli": "bun run src/cli/index.tsx",
|
|
12610
|
+
"dev:mcp": "bun run src/mcp/index.ts",
|
|
12611
|
+
"dev:serve": "bun run src/server/index.ts",
|
|
12612
|
+
prepublishOnly: "bun run build",
|
|
12613
|
+
postinstall: "mkdir -p $HOME/.hasna/testers/screenshots $HOME/.hasna/testers/browser/profiles 2>/dev/null || true"
|
|
12614
|
+
},
|
|
12615
|
+
dependencies: {
|
|
12616
|
+
"@anthropic-ai/sdk": "^0.52.0",
|
|
12617
|
+
"@hasna/browser": "^0.3.8",
|
|
12618
|
+
"@hasna/cloud": "^0.1.24",
|
|
12619
|
+
"@hasna/contacts": "^0.6.8",
|
|
12620
|
+
"@modelcontextprotocol/sdk": "^1.12.1",
|
|
12621
|
+
chalk: "^5.4.1",
|
|
12622
|
+
commander: "^13.1.0",
|
|
12623
|
+
ink: "^5.2.0",
|
|
12624
|
+
playwright: "^1.50.0",
|
|
12625
|
+
react: "^18.3.1",
|
|
12626
|
+
zod: "^3.24.2"
|
|
12627
|
+
},
|
|
12628
|
+
devDependencies: {
|
|
12629
|
+
"@types/bun": "latest",
|
|
12630
|
+
"@types/react": "^18.3.18",
|
|
12631
|
+
typescript: "^5.7.3"
|
|
12632
|
+
},
|
|
12633
|
+
engines: {
|
|
12634
|
+
bun: ">=1.0.0"
|
|
12635
|
+
},
|
|
12636
|
+
publishConfig: {
|
|
12637
|
+
registry: "https://registry.npmjs.org",
|
|
12638
|
+
access: "public"
|
|
12639
|
+
},
|
|
12640
|
+
repository: {
|
|
12641
|
+
type: "git",
|
|
12642
|
+
url: "git+https://github.com/hasna/testers.git"
|
|
12643
|
+
},
|
|
12644
|
+
license: "Apache-2.0",
|
|
12645
|
+
keywords: [
|
|
12646
|
+
"testing",
|
|
12647
|
+
"qa",
|
|
12648
|
+
"ai",
|
|
12649
|
+
"playwright",
|
|
12650
|
+
"browser",
|
|
12651
|
+
"screenshot",
|
|
12652
|
+
"automation",
|
|
12653
|
+
"cli",
|
|
12654
|
+
"mcp"
|
|
12655
|
+
]
|
|
12656
|
+
};
|
|
12657
|
+
|
|
12658
|
+
// src/server/index.ts
|
|
12659
|
+
init_paths();
|
|
12575
12660
|
|
|
12576
12661
|
// node_modules/zod/v3/external.js
|
|
12577
12662
|
var exports_external = {};
|
|
@@ -20272,7 +20357,7 @@ Environment:
|
|
|
20272
20357
|
process.exit(0);
|
|
20273
20358
|
}
|
|
20274
20359
|
if (cliArgs.has("--version") || cliArgs.has("-V")) {
|
|
20275
|
-
console.log(
|
|
20360
|
+
console.log(package_default.version);
|
|
20276
20361
|
process.exit(0);
|
|
20277
20362
|
}
|
|
20278
20363
|
function parseUrl(req) {
|
|
@@ -20475,7 +20560,7 @@ async function handleRequest(req) {
|
|
|
20475
20560
|
runCount: runs.length,
|
|
20476
20561
|
apiCheckCount: countApiChecks(),
|
|
20477
20562
|
personaCount: countPersonas(),
|
|
20478
|
-
version:
|
|
20563
|
+
version: package_default.version
|
|
20479
20564
|
});
|
|
20480
20565
|
}
|
|
20481
20566
|
if (pathname === "/api/scenarios/search" && method === "GET") {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hasna/testers",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.32",
|
|
4
4
|
"description": "AI-powered QA testing CLI — spawns cheap AI agents to test web apps with headless browsers",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -65,7 +65,7 @@
|
|
|
65
65
|
},
|
|
66
66
|
"repository": {
|
|
67
67
|
"type": "git",
|
|
68
|
-
"url": "https://github.com/hasna/testers.git"
|
|
68
|
+
"url": "git+https://github.com/hasna/testers.git"
|
|
69
69
|
},
|
|
70
70
|
"license": "Apache-2.0",
|
|
71
71
|
"keywords": [
|
package/dist/db/sessions.d.ts
DELETED
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
export interface SessionInput {
|
|
2
|
-
sessionId?: string;
|
|
3
|
-
tabId: number;
|
|
4
|
-
url?: string;
|
|
5
|
-
title?: string;
|
|
6
|
-
entries: string;
|
|
7
|
-
entryCount: number;
|
|
8
|
-
errorCount?: number;
|
|
9
|
-
consoleCount?: number;
|
|
10
|
-
navCount?: number;
|
|
11
|
-
status: "live" | "saved" | "exported";
|
|
12
|
-
startTime: string;
|
|
13
|
-
endTime?: string;
|
|
14
|
-
}
|
|
15
|
-
export declare function createSession(input: SessionInput): Session;
|
|
16
|
-
export declare function getSession(id: string): Session | null;
|
|
17
|
-
export declare function listSessions(limit?: number, offset?: number): Session[];
|
|
18
|
-
export declare function deleteSession(id: string): boolean;
|
|
19
|
-
export declare function searchSessions(query: string, limit?: number): Session[];
|
|
20
|
-
export declare function countSessions(): number;
|
|
21
|
-
export interface Session {
|
|
22
|
-
id: string;
|
|
23
|
-
tabId: number;
|
|
24
|
-
url: string | null;
|
|
25
|
-
title: string | null;
|
|
26
|
-
entries: unknown[];
|
|
27
|
-
entryCount: number;
|
|
28
|
-
errorCount: number;
|
|
29
|
-
consoleCount: number;
|
|
30
|
-
navCount: number;
|
|
31
|
-
status: string;
|
|
32
|
-
startTime: string;
|
|
33
|
-
endTime: string | null;
|
|
34
|
-
createdAt: string;
|
|
35
|
-
}
|
|
36
|
-
//# sourceMappingURL=sessions.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sessions.d.ts","sourceRoot":"","sources":["../../src/db/sessions.ts"],"names":[],"mappings":"AAIA,MAAM,WAAW,YAAY;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,MAAM,GAAG,OAAO,GAAG,UAAU,CAAC;IACtC,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,wBAAgB,aAAa,CAAC,KAAK,EAAE,YAAY,WAyBhD;AAED,wBAAgB,UAAU,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,GAAG,IAAI,CAYrD;AAED,wBAAgB,YAAY,CAAC,KAAK,SAAK,EAAE,MAAM,SAAI,GAAG,OAAO,EAAE,CAM9D;AAED,wBAAgB,aAAa,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAIjD;AAED,wBAAgB,cAAc,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,SAAK,GAAG,OAAO,EAAE,CAMnE;AAED,wBAAgB,aAAa,IAAI,MAAM,CAItC;AAoBD,MAAM,WAAW,OAAO;IACtB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,EAAE,MAAM,GAAG,IAAI,CAAC;IACnB,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,OAAO,EAAE,OAAO,EAAE,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,SAAS,EAAE,MAAM,CAAC;CACnB"}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import type { Page } from "playwright";
|
|
2
|
-
export interface AriaSnapshot {
|
|
3
|
-
tree: string;
|
|
4
|
-
interactive_count: number;
|
|
5
|
-
refs: Record<string, {
|
|
6
|
-
role: string;
|
|
7
|
-
name: string;
|
|
8
|
-
}>;
|
|
9
|
-
}
|
|
10
|
-
export declare function takeSnapshot(page: Page, sessionId: string): Promise<AriaSnapshot>;
|
|
11
|
-
export declare function getRefLocator(page: Page, sessionId: string, ref: string): Promise<ReturnType<Page["locator"]>>;
|
|
12
|
-
export declare function applyStealthPatches(page: Page): Promise<void>;
|
|
13
|
-
export declare function getDeepPerformance(page: Page): Promise<unknown>;
|
|
14
|
-
//# sourceMappingURL=browser-compat.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"browser-compat.d.ts","sourceRoot":"","sources":["../../src/lib/browser-compat.ts"],"names":[],"mappings":"AAWA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;AAavC,MAAM,WAAW,YAAY;IAC3B,IAAI,EAAE,MAAM,CAAC;IACb,iBAAiB,EAAE,MAAM,CAAC;IAC1B,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;CACtD;AAED,wBAAsB,YAAY,CAAC,IAAI,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,YAAY,CAAC,CAcvF;AAED,wBAAsB,aAAa,CACjC,IAAI,EAAE,IAAI,EACV,SAAS,EAAE,MAAM,EACjB,GAAG,EAAE,MAAM,GACV,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,CAOtC;AAID,wBAAsB,mBAAmB,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAkBnE;AAID,wBAAsB,kBAAkB,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,OAAO,CAAC,CASrE"}
|
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
export interface RepoSpec {
|
|
2
|
-
/** Relative path to the spec file */
|
|
3
|
-
file: string;
|
|
4
|
-
/** Glob pattern that matched this file */
|
|
5
|
-
fromGlob: string;
|
|
6
|
-
/** Number of tests described in the file (approximate, parsed from file text) */
|
|
7
|
-
testCount: number;
|
|
8
|
-
/** File mtime in ms (used for cache invalidation) */
|
|
9
|
-
mtimeMs: number;
|
|
10
|
-
/** File content hash (used for cache invalidation) */
|
|
11
|
-
contentHash: string;
|
|
12
|
-
}
|
|
13
|
-
export interface PackageManagers {
|
|
14
|
-
npm: boolean;
|
|
15
|
-
yarn: boolean;
|
|
16
|
-
pnpm: boolean;
|
|
17
|
-
bun: boolean;
|
|
18
|
-
/** Detected preferred package manager */
|
|
19
|
-
preferred: "npm" | "yarn" | "pnpm" | "bun";
|
|
20
|
-
}
|
|
21
|
-
export interface DevScripts {
|
|
22
|
-
/** Script that starts the dev/test server (if found) */
|
|
23
|
-
dev: string | null;
|
|
24
|
-
/** Script for test-only mode (if found) */
|
|
25
|
-
test: string | null;
|
|
26
|
-
/** Script to seed/fill test database */
|
|
27
|
-
seed: string | null;
|
|
28
|
-
/** Script to build the app */
|
|
29
|
-
build: string | null;
|
|
30
|
-
}
|
|
31
|
-
export interface ReadinessCheck {
|
|
32
|
-
/** Playwright is installed */
|
|
33
|
-
playwrightInstalled: boolean;
|
|
34
|
-
/** Browsers are downloaded */
|
|
35
|
-
browsersInstalled: boolean;
|
|
36
|
-
/** Playwright config file exists */
|
|
37
|
-
configExists: boolean;
|
|
38
|
-
/** Spec files exist and are readable */
|
|
39
|
-
specsFound: boolean;
|
|
40
|
-
/** All checks passed */
|
|
41
|
-
ready: boolean;
|
|
42
|
-
/** Human-readable issues if not ready */
|
|
43
|
-
issues: string[];
|
|
44
|
-
}
|
|
45
|
-
export interface RepoPrep {
|
|
46
|
-
/** Command to install dependencies */
|
|
47
|
-
installCmd: string | null;
|
|
48
|
-
/** Command to install Playwright browsers */
|
|
49
|
-
installBrowsersCmd: string | null;
|
|
50
|
-
/** Command to start dev server */
|
|
51
|
-
startDevCmd: string | null;
|
|
52
|
-
/** Command to build */
|
|
53
|
-
buildCmd: string | null;
|
|
54
|
-
/** Command to seed database */
|
|
55
|
-
seedCmd: string | null;
|
|
56
|
-
}
|
|
57
|
-
export interface RepoDiscoverySnapshot {
|
|
58
|
-
/** Absolute path to the repo root */
|
|
59
|
-
repoPath: string;
|
|
60
|
-
/** Playwright config file path (relative to repo) */
|
|
61
|
-
configPath: string | null;
|
|
62
|
-
/** Playwright config content parsed (or null if unparseable) */
|
|
63
|
-
configRaw: string | null;
|
|
64
|
-
/** Spec files discovered */
|
|
65
|
-
specs: RepoSpec[];
|
|
66
|
-
/** Total approximate test count across all specs */
|
|
67
|
-
totalTests: number;
|
|
68
|
-
/** Package manager detection */
|
|
69
|
-
packageManager: PackageManagers;
|
|
70
|
-
/** Dev-related scripts from package.json */
|
|
71
|
-
devScripts: DevScripts;
|
|
72
|
-
/** Readiness assessment */
|
|
73
|
-
readiness: ReadinessCheck;
|
|
74
|
-
/** Prep commands that could be run with --apply */
|
|
75
|
-
prep: RepoPrep;
|
|
76
|
-
/** Suggested base URL for the dev server */
|
|
77
|
-
suggestedUrl: string | null;
|
|
78
|
-
/** Suggested working directory for running tests */
|
|
79
|
-
workingDir: string;
|
|
80
|
-
/** When the snapshot was taken (ISO timestamp) */
|
|
81
|
-
snapshotAt: string;
|
|
82
|
-
/** Cache key for this snapshot (path hash + spec file hashes) */
|
|
83
|
-
cacheKey: string;
|
|
84
|
-
}
|
|
85
|
-
export interface DiscoveryOptions {
|
|
86
|
-
/** Absolute path to the repo root */
|
|
87
|
-
repoPath: string;
|
|
88
|
-
/** Force a fresh scan, ignoring cache */
|
|
89
|
-
refresh?: boolean;
|
|
90
|
-
/** Override the working directory for running tests */
|
|
91
|
-
workingDir?: string;
|
|
92
|
-
/** Override base URL */
|
|
93
|
-
baseUrl?: string;
|
|
94
|
-
}
|
|
95
|
-
export declare function discoverRepo(opts: DiscoveryOptions): RepoDiscoverySnapshot;
|
|
96
|
-
export declare function clearDiscoveryCache(repoPath?: string): void;
|
|
97
|
-
export declare function getDiscoveryCacheInfo(repoPath: string): {
|
|
98
|
-
cached: boolean;
|
|
99
|
-
stale: boolean;
|
|
100
|
-
path: string;
|
|
101
|
-
} | null;
|
|
102
|
-
//# sourceMappingURL=repo-discovery.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"repo-discovery.d.ts","sourceRoot":"","sources":["../../src/lib/repo-discovery.ts"],"names":[],"mappings":"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"}
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
import type { RepoDiscoverySnapshot } from "./repo-discovery.js";
|
|
2
|
-
export interface RepoRunSpecResult {
|
|
3
|
-
specFile: string;
|
|
4
|
-
status: "passed" | "failed" | "error" | "skipped";
|
|
5
|
-
exitCode: number | null;
|
|
6
|
-
stdout: string;
|
|
7
|
-
stderr: string;
|
|
8
|
-
durationMs: number;
|
|
9
|
-
/** Parseable test names and their individual status */
|
|
10
|
-
testResults: {
|
|
11
|
-
name: string;
|
|
12
|
-
status: "passed" | "failed" | "skipped";
|
|
13
|
-
}[];
|
|
14
|
-
error?: string;
|
|
15
|
-
}
|
|
16
|
-
export interface RepoRunOptions {
|
|
17
|
-
/** Discovery snapshot for the repo */
|
|
18
|
-
snapshot: RepoDiscoverySnapshot;
|
|
19
|
-
/** Specific spec files to run (defaults to all discovered) */
|
|
20
|
-
specFiles?: string[];
|
|
21
|
-
/** Extra args to pass to Playwright */
|
|
22
|
-
extraArgs?: string[];
|
|
23
|
-
/** Timeout per spec file in ms */
|
|
24
|
-
timeout?: number;
|
|
25
|
-
/** Project ID for result storage */
|
|
26
|
-
projectId?: string;
|
|
27
|
-
/** URL the dev server is running on */
|
|
28
|
-
url?: string;
|
|
29
|
-
/** Model hint (stored in run metadata) */
|
|
30
|
-
model?: string;
|
|
31
|
-
/** Run label */
|
|
32
|
-
label?: string;
|
|
33
|
-
}
|
|
34
|
-
export interface RepoRunResult {
|
|
35
|
-
runId: string;
|
|
36
|
-
specResults: RepoRunSpecResult[];
|
|
37
|
-
total: number;
|
|
38
|
-
passed: number;
|
|
39
|
-
failed: number;
|
|
40
|
-
skipped: number;
|
|
41
|
-
errored: number;
|
|
42
|
-
durationMs: number;
|
|
43
|
-
status: "passed" | "failed" | "error";
|
|
44
|
-
}
|
|
45
|
-
export declare function runRepoTests(opts: RepoRunOptions): Promise<RepoRunResult>;
|
|
46
|
-
export interface PrepResult {
|
|
47
|
-
steps: {
|
|
48
|
-
cmd: string;
|
|
49
|
-
success: boolean;
|
|
50
|
-
output: string;
|
|
51
|
-
durationMs: number;
|
|
52
|
-
}[];
|
|
53
|
-
allSucceeded: boolean;
|
|
54
|
-
}
|
|
55
|
-
export declare function runPrep(snapshot: RepoDiscoverySnapshot, steps: ("install" | "browsers" | "dev" | "build" | "seed")[]): PrepResult;
|
|
56
|
-
//# sourceMappingURL=repo-executor.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"repo-executor.d.ts","sourceRoot":"","sources":["../../src/lib/repo-executor.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,qBAAqB,EAAY,MAAM,qBAAqB,CAAC;AAI3E,MAAM,WAAW,iBAAiB;IAChC,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,QAAQ,GAAG,QAAQ,GAAG,OAAO,GAAG,SAAS,CAAC;IAClD,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;IACnB,uDAAuD;IACvD,WAAW,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,QAAQ,GAAG,QAAQ,GAAG,SAAS,CAAA;KAAE,EAAE,CAAC;IACzE,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,cAAc;IAC7B,sCAAsC;IACtC,QAAQ,EAAE,qBAAqB,CAAC;IAChC,8DAA8D;IAC9D,SAAS,CAAC,EAAE,MAAM,EAAE,CAAC;IACrB,uCAAuC;IACvC,SAAS,CAAC,EAAE,MAAM,EAAE,CAAC;IACrB,kCAAkC;IAClC,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,oCAAoC;IACpC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,uCAAuC;IACvC,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,0CAA0C;IAC1C,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,gBAAgB;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,aAAa;IAC5B,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,iBAAiB,EAAE,CAAC;IACjC,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,QAAQ,GAAG,QAAQ,GAAG,OAAO,CAAC;CACvC;AAoMD,wBAAsB,YAAY,CAAC,IAAI,EAAE,cAAc,GAAG,OAAO,CAAC,aAAa,CAAC,CAyH/E;AAID,MAAM,WAAW,UAAU;IACzB,KAAK,EAAE;QAAE,GAAG,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,OAAO,CAAC;QAAC,MAAM,EAAE,MAAM,CAAC;QAAC,UAAU,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;IAC/E,YAAY,EAAE,OAAO,CAAC;CACvB;AAED,wBAAgB,OAAO,CACrB,QAAQ,EAAE,qBAAqB,EAC/B,KAAK,EAAE,CAAC,SAAS,GAAG,UAAU,GAAG,KAAK,GAAG,OAAO,GAAG,MAAM,CAAC,EAAE,GAC3D,UAAU,CAkDZ"}
|