xibecode 0.3.5 → 0.4.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.
- package/LICENSE +201 -0
- package/README.md +255 -904
- package/dist/commands/chat.d.ts +1 -0
- package/dist/commands/chat.d.ts.map +1 -1
- package/dist/commands/chat.js +106 -8
- package/dist/commands/chat.js.map +1 -1
- package/dist/core/modes.d.ts +302 -14
- package/dist/core/modes.d.ts.map +1 -1
- package/dist/core/modes.js +81 -9
- package/dist/core/modes.js.map +1 -1
- package/dist/core/session-bridge.d.ts +105 -0
- package/dist/core/session-bridge.d.ts.map +1 -0
- package/dist/core/session-bridge.js +243 -0
- package/dist/core/session-bridge.js.map +1 -0
- package/dist/core/tools.d.ts +359 -0
- package/dist/core/tools.d.ts.map +1 -1
- package/dist/core/tools.js +631 -1
- package/dist/core/tools.js.map +1 -1
- package/dist/index.js +42 -35
- package/dist/index.js.map +1 -1
- package/dist/tools/browser.d.ts +112 -0
- package/dist/tools/browser.d.ts.map +1 -1
- package/dist/tools/browser.js +396 -13
- package/dist/tools/browser.js.map +1 -1
- package/dist/tools/test-generator.d.ts +157 -0
- package/dist/tools/test-generator.d.ts.map +1 -0
- package/dist/tools/test-generator.js +893 -0
- package/dist/tools/test-generator.js.map +1 -0
- package/dist/webui/server.d.ts +96 -0
- package/dist/webui/server.d.ts.map +1 -0
- package/dist/webui/server.js +2132 -0
- package/dist/webui/server.js.map +1 -0
- package/package.json +30 -14
- package/webui-dist/assets/index-BlYSY3Lp.js +338 -0
- package/webui-dist/assets/index-BlYSY3Lp.js.map +1 -0
- package/webui-dist/assets/index-DS6Gij8T.css +32 -0
- package/webui-dist/assets/xterm-BUw9jMN8.js +10 -0
- package/webui-dist/assets/xterm-BUw9jMN8.js.map +1 -0
- package/webui-dist/assets/xterm-addon-fit-CMYoGiLV.js +2 -0
- package/webui-dist/assets/xterm-addon-fit-CMYoGiLV.js.map +1 -0
- package/webui-dist/assets/xterm-addon-web-links-mCwMW5Oc.js +2 -0
- package/webui-dist/assets/xterm-addon-web-links-mCwMW5Oc.js.map +1 -0
- package/webui-dist/index.html +15 -0
package/dist/tools/browser.js
CHANGED
|
@@ -1,28 +1,62 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { chromium } from 'playwright';
|
|
2
|
+
import * as fs from 'fs/promises';
|
|
3
|
+
import * as path from 'path';
|
|
4
|
+
/**
|
|
5
|
+
* Default viewports for responsive testing
|
|
6
|
+
*/
|
|
7
|
+
export const DEFAULT_VIEWPORTS = [
|
|
8
|
+
{ name: 'mobile', width: 375, height: 667 },
|
|
9
|
+
{ name: 'tablet', width: 768, height: 1024 },
|
|
10
|
+
{ name: 'desktop', width: 1280, height: 800 },
|
|
11
|
+
{ name: 'desktop-large', width: 1920, height: 1080 },
|
|
12
|
+
];
|
|
13
|
+
/**
|
|
14
|
+
* BrowserManager - Playwright-based browser automation for XibeCode
|
|
15
|
+
*
|
|
16
|
+
* Provides tools for:
|
|
17
|
+
* - Screenshot capture
|
|
18
|
+
* - Console log collection
|
|
19
|
+
* - Visual regression testing
|
|
20
|
+
* - Performance metrics (Core Web Vitals)
|
|
21
|
+
* - Accessibility auditing
|
|
22
|
+
* - Responsive testing
|
|
23
|
+
* - Network monitoring
|
|
24
|
+
*/
|
|
2
25
|
export class BrowserManager {
|
|
3
26
|
browser = null;
|
|
27
|
+
context = null;
|
|
4
28
|
async getBrowser() {
|
|
5
29
|
if (!this.browser) {
|
|
6
|
-
this.browser = await
|
|
30
|
+
this.browser = await chromium.launch({
|
|
7
31
|
headless: true,
|
|
8
|
-
args: ['--no-sandbox', '--disable-setuid-sandbox'],
|
|
32
|
+
args: ['--no-sandbox', '--disable-setuid-sandbox'],
|
|
9
33
|
});
|
|
34
|
+
this.context = await this.browser.newContext();
|
|
10
35
|
}
|
|
11
|
-
|
|
36
|
+
if (!this.context) {
|
|
37
|
+
this.context = await this.browser.newContext();
|
|
38
|
+
}
|
|
39
|
+
return this.context;
|
|
12
40
|
}
|
|
13
41
|
async close() {
|
|
42
|
+
if (this.context) {
|
|
43
|
+
await this.context.close();
|
|
44
|
+
this.context = null;
|
|
45
|
+
}
|
|
14
46
|
if (this.browser) {
|
|
15
47
|
await this.browser.close();
|
|
16
48
|
this.browser = null;
|
|
17
49
|
}
|
|
18
50
|
}
|
|
51
|
+
/**
|
|
52
|
+
* Take a screenshot of a webpage
|
|
53
|
+
*/
|
|
19
54
|
async takeScreenshot(url, outputPath, fullPage = true) {
|
|
20
|
-
const
|
|
21
|
-
const page = await
|
|
55
|
+
const context = await this.getBrowser();
|
|
56
|
+
const page = await context.newPage();
|
|
22
57
|
try {
|
|
23
|
-
await page.
|
|
24
|
-
|
|
25
|
-
await page.goto(url, { waitUntil: 'networkidle0', timeout: 30000 });
|
|
58
|
+
await page.setViewportSize({ width: 1280, height: 800 });
|
|
59
|
+
await page.goto(url, { waitUntil: 'networkidle', timeout: 30000 });
|
|
26
60
|
await page.screenshot({ path: outputPath, fullPage });
|
|
27
61
|
return `Screenshot saved to ${outputPath}`;
|
|
28
62
|
}
|
|
@@ -33,16 +67,18 @@ export class BrowserManager {
|
|
|
33
67
|
await page.close();
|
|
34
68
|
}
|
|
35
69
|
}
|
|
70
|
+
/**
|
|
71
|
+
* Get console logs from a webpage
|
|
72
|
+
*/
|
|
36
73
|
async getConsoleLogs(url, timeout = 5000) {
|
|
37
|
-
const
|
|
38
|
-
const page = await
|
|
74
|
+
const context = await this.getBrowser();
|
|
75
|
+
const page = await context.newPage();
|
|
39
76
|
const logs = [];
|
|
40
77
|
page.on('console', (msg) => logs.push(`[${msg.type()}] ${msg.text()}`));
|
|
41
78
|
page.on('pageerror', (err) => logs.push(`[error] ${err.message}`));
|
|
42
79
|
try {
|
|
43
80
|
await page.goto(url, { waitUntil: 'domcontentloaded', timeout: 30000 });
|
|
44
|
-
|
|
45
|
-
await new Promise(resolve => setTimeout(resolve, timeout));
|
|
81
|
+
await page.waitForTimeout(timeout);
|
|
46
82
|
return logs;
|
|
47
83
|
}
|
|
48
84
|
catch (error) {
|
|
@@ -52,5 +88,352 @@ export class BrowserManager {
|
|
|
52
88
|
await page.close();
|
|
53
89
|
}
|
|
54
90
|
}
|
|
91
|
+
/**
|
|
92
|
+
* Run a visual regression test by comparing screenshots
|
|
93
|
+
*/
|
|
94
|
+
async runVisualTest(url, baselinePath, outputDir = '.playwright-baselines') {
|
|
95
|
+
const context = await this.getBrowser();
|
|
96
|
+
const page = await context.newPage();
|
|
97
|
+
try {
|
|
98
|
+
await page.setViewportSize({ width: 1280, height: 800 });
|
|
99
|
+
await page.goto(url, { waitUntil: 'networkidle', timeout: 30000 });
|
|
100
|
+
// Ensure output directory exists
|
|
101
|
+
await fs.mkdir(outputDir, { recursive: true });
|
|
102
|
+
const screenshotPath = path.join(outputDir, 'current.png');
|
|
103
|
+
await page.screenshot({ path: screenshotPath, fullPage: true });
|
|
104
|
+
// Check if baseline exists
|
|
105
|
+
let baselineExists = false;
|
|
106
|
+
try {
|
|
107
|
+
await fs.access(baselinePath);
|
|
108
|
+
baselineExists = true;
|
|
109
|
+
}
|
|
110
|
+
catch {
|
|
111
|
+
// Baseline doesn't exist, create it
|
|
112
|
+
await fs.copyFile(screenshotPath, baselinePath);
|
|
113
|
+
return {
|
|
114
|
+
match: true,
|
|
115
|
+
diffPercentage: 0,
|
|
116
|
+
baselineExists: false,
|
|
117
|
+
screenshotPath,
|
|
118
|
+
};
|
|
119
|
+
}
|
|
120
|
+
// Simple pixel comparison (for basic visual testing)
|
|
121
|
+
const currentBuffer = await fs.readFile(screenshotPath);
|
|
122
|
+
const baselineBuffer = await fs.readFile(baselinePath);
|
|
123
|
+
const match = currentBuffer.equals(baselineBuffer);
|
|
124
|
+
return {
|
|
125
|
+
match,
|
|
126
|
+
diffPercentage: match ? 0 : 100, // Simplified - would need pixelmatch for accurate diff
|
|
127
|
+
baselineExists: true,
|
|
128
|
+
screenshotPath,
|
|
129
|
+
};
|
|
130
|
+
}
|
|
131
|
+
catch (error) {
|
|
132
|
+
throw new Error(`Visual test failed: ${error.message}`);
|
|
133
|
+
}
|
|
134
|
+
finally {
|
|
135
|
+
await page.close();
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
/**
|
|
139
|
+
* Check basic accessibility issues on a page
|
|
140
|
+
*/
|
|
141
|
+
async checkAccessibility(url) {
|
|
142
|
+
const context = await this.getBrowser();
|
|
143
|
+
const page = await context.newPage();
|
|
144
|
+
const issues = [];
|
|
145
|
+
try {
|
|
146
|
+
await page.goto(url, { waitUntil: 'networkidle', timeout: 30000 });
|
|
147
|
+
// Check for common accessibility issues
|
|
148
|
+
const checks = await page.evaluate(() => {
|
|
149
|
+
const issues = [];
|
|
150
|
+
// Check images without alt text
|
|
151
|
+
document.querySelectorAll('img').forEach((img, i) => {
|
|
152
|
+
if (!img.alt && !img.getAttribute('aria-label')) {
|
|
153
|
+
issues.push({
|
|
154
|
+
type: 'error',
|
|
155
|
+
message: 'Image missing alt text',
|
|
156
|
+
selector: `img:nth-of-type(${i + 1})`,
|
|
157
|
+
context: img.src?.substring(0, 50),
|
|
158
|
+
});
|
|
159
|
+
}
|
|
160
|
+
});
|
|
161
|
+
// Check form inputs without labels
|
|
162
|
+
document.querySelectorAll('input, select, textarea').forEach((input, i) => {
|
|
163
|
+
const id = input.id;
|
|
164
|
+
const hasLabel = id && document.querySelector(`label[for="${id}"]`);
|
|
165
|
+
const hasAriaLabel = input.getAttribute('aria-label') || input.getAttribute('aria-labelledby');
|
|
166
|
+
if (!hasLabel && !hasAriaLabel) {
|
|
167
|
+
issues.push({
|
|
168
|
+
type: 'error',
|
|
169
|
+
message: 'Form input missing label',
|
|
170
|
+
selector: `${input.tagName.toLowerCase()}:nth-of-type(${i + 1})`,
|
|
171
|
+
context: input.getAttribute('name') || input.getAttribute('placeholder') || undefined,
|
|
172
|
+
});
|
|
173
|
+
}
|
|
174
|
+
});
|
|
175
|
+
// Check for empty links
|
|
176
|
+
document.querySelectorAll('a').forEach((link, i) => {
|
|
177
|
+
const hasText = link.textContent?.trim();
|
|
178
|
+
const hasAriaLabel = link.getAttribute('aria-label');
|
|
179
|
+
const hasTitle = link.getAttribute('title');
|
|
180
|
+
if (!hasText && !hasAriaLabel && !hasTitle) {
|
|
181
|
+
issues.push({
|
|
182
|
+
type: 'warning',
|
|
183
|
+
message: 'Link has no accessible text',
|
|
184
|
+
selector: `a:nth-of-type(${i + 1})`,
|
|
185
|
+
context: link.href?.substring(0, 50),
|
|
186
|
+
});
|
|
187
|
+
}
|
|
188
|
+
});
|
|
189
|
+
// Check for missing document language
|
|
190
|
+
if (!document.documentElement.lang) {
|
|
191
|
+
issues.push({
|
|
192
|
+
type: 'warning',
|
|
193
|
+
message: 'Document missing lang attribute',
|
|
194
|
+
selector: 'html',
|
|
195
|
+
});
|
|
196
|
+
}
|
|
197
|
+
// Check for missing page title
|
|
198
|
+
if (!document.title) {
|
|
199
|
+
issues.push({
|
|
200
|
+
type: 'error',
|
|
201
|
+
message: 'Page missing title',
|
|
202
|
+
selector: 'head',
|
|
203
|
+
});
|
|
204
|
+
}
|
|
205
|
+
// Check heading hierarchy
|
|
206
|
+
const headings = Array.from(document.querySelectorAll('h1, h2, h3, h4, h5, h6'));
|
|
207
|
+
let lastLevel = 0;
|
|
208
|
+
headings.forEach((heading, i) => {
|
|
209
|
+
const level = parseInt(heading.tagName[1]);
|
|
210
|
+
if (level > lastLevel + 1 && lastLevel !== 0) {
|
|
211
|
+
issues.push({
|
|
212
|
+
type: 'warning',
|
|
213
|
+
message: `Heading level skipped from h${lastLevel} to h${level}`,
|
|
214
|
+
selector: `${heading.tagName.toLowerCase()}:nth-of-type(${i + 1})`,
|
|
215
|
+
context: heading.textContent?.substring(0, 30),
|
|
216
|
+
});
|
|
217
|
+
}
|
|
218
|
+
lastLevel = level;
|
|
219
|
+
});
|
|
220
|
+
// Check for sufficient color contrast (basic check)
|
|
221
|
+
const buttons = document.querySelectorAll('button, [role="button"]');
|
|
222
|
+
buttons.forEach((button, i) => {
|
|
223
|
+
const styles = window.getComputedStyle(button);
|
|
224
|
+
if (styles.backgroundColor === 'transparent' && !button.querySelector('img, svg')) {
|
|
225
|
+
issues.push({
|
|
226
|
+
type: 'notice',
|
|
227
|
+
message: 'Button may have contrast issues',
|
|
228
|
+
selector: `button:nth-of-type(${i + 1})`,
|
|
229
|
+
context: button.textContent?.substring(0, 30),
|
|
230
|
+
});
|
|
231
|
+
}
|
|
232
|
+
});
|
|
233
|
+
return issues;
|
|
234
|
+
});
|
|
235
|
+
return checks.map(c => ({
|
|
236
|
+
type: c.type,
|
|
237
|
+
message: c.message,
|
|
238
|
+
selector: c.selector,
|
|
239
|
+
context: c.context,
|
|
240
|
+
}));
|
|
241
|
+
}
|
|
242
|
+
catch (error) {
|
|
243
|
+
throw new Error(`Accessibility check failed: ${error.message}`);
|
|
244
|
+
}
|
|
245
|
+
finally {
|
|
246
|
+
await page.close();
|
|
247
|
+
}
|
|
248
|
+
}
|
|
249
|
+
/**
|
|
250
|
+
* Measure Core Web Vitals and performance metrics
|
|
251
|
+
*/
|
|
252
|
+
async measurePerformance(url) {
|
|
253
|
+
const context = await this.getBrowser();
|
|
254
|
+
const page = await context.newPage();
|
|
255
|
+
try {
|
|
256
|
+
const startTime = Date.now();
|
|
257
|
+
// Navigate and measure timing
|
|
258
|
+
await page.goto(url, { waitUntil: 'load', timeout: 30000 });
|
|
259
|
+
const loadTime = Date.now() - startTime;
|
|
260
|
+
// Get performance metrics from browser
|
|
261
|
+
const metrics = await page.evaluate(() => {
|
|
262
|
+
const perf = performance;
|
|
263
|
+
const navigation = perf.getEntriesByType('navigation')[0];
|
|
264
|
+
const paint = perf.getEntriesByType('paint');
|
|
265
|
+
// Get First Contentful Paint
|
|
266
|
+
const fcp = paint.find(p => p.name === 'first-contentful-paint');
|
|
267
|
+
// Get Largest Contentful Paint (if available)
|
|
268
|
+
let lcp = null;
|
|
269
|
+
try {
|
|
270
|
+
const lcpEntries = perf.getEntriesByType('largest-contentful-paint');
|
|
271
|
+
if (lcpEntries.length > 0) {
|
|
272
|
+
lcp = lcpEntries[lcpEntries.length - 1].startTime;
|
|
273
|
+
}
|
|
274
|
+
}
|
|
275
|
+
catch {
|
|
276
|
+
// LCP not available
|
|
277
|
+
}
|
|
278
|
+
// Get Cumulative Layout Shift (if available)
|
|
279
|
+
let cls = null;
|
|
280
|
+
try {
|
|
281
|
+
const layoutShiftEntries = perf.getEntriesByType('layout-shift');
|
|
282
|
+
cls = layoutShiftEntries
|
|
283
|
+
.filter(entry => !entry.hadRecentInput)
|
|
284
|
+
.reduce((sum, entry) => sum + entry.value, 0);
|
|
285
|
+
}
|
|
286
|
+
catch {
|
|
287
|
+
// CLS not available
|
|
288
|
+
}
|
|
289
|
+
return {
|
|
290
|
+
domContentLoaded: navigation?.domContentLoadedEventEnd - navigation?.startTime || 0,
|
|
291
|
+
firstContentfulPaint: fcp?.startTime || null,
|
|
292
|
+
largestContentfulPaint: lcp,
|
|
293
|
+
cumulativeLayoutShift: cls,
|
|
294
|
+
timeToInteractive: navigation?.domInteractive - navigation?.startTime || null,
|
|
295
|
+
};
|
|
296
|
+
});
|
|
297
|
+
return {
|
|
298
|
+
url,
|
|
299
|
+
loadTime,
|
|
300
|
+
domContentLoaded: metrics.domContentLoaded,
|
|
301
|
+
firstContentfulPaint: metrics.firstContentfulPaint,
|
|
302
|
+
largestContentfulPaint: metrics.largestContentfulPaint,
|
|
303
|
+
cumulativeLayoutShift: metrics.cumulativeLayoutShift,
|
|
304
|
+
timeToInteractive: metrics.timeToInteractive,
|
|
305
|
+
};
|
|
306
|
+
}
|
|
307
|
+
catch (error) {
|
|
308
|
+
throw new Error(`Performance measurement failed: ${error.message}`);
|
|
309
|
+
}
|
|
310
|
+
finally {
|
|
311
|
+
await page.close();
|
|
312
|
+
}
|
|
313
|
+
}
|
|
314
|
+
/**
|
|
315
|
+
* Test a page across multiple viewport sizes
|
|
316
|
+
*/
|
|
317
|
+
async testResponsive(url, outputDir, viewports = DEFAULT_VIEWPORTS) {
|
|
318
|
+
const context = await this.getBrowser();
|
|
319
|
+
const results = [];
|
|
320
|
+
// Ensure output directory exists
|
|
321
|
+
await fs.mkdir(outputDir, { recursive: true });
|
|
322
|
+
for (const viewport of viewports) {
|
|
323
|
+
const page = await context.newPage();
|
|
324
|
+
const errors = [];
|
|
325
|
+
page.on('pageerror', (err) => errors.push(err.message));
|
|
326
|
+
page.on('console', (msg) => {
|
|
327
|
+
if (msg.type() === 'error') {
|
|
328
|
+
errors.push(msg.text());
|
|
329
|
+
}
|
|
330
|
+
});
|
|
331
|
+
try {
|
|
332
|
+
await page.setViewportSize({ width: viewport.width, height: viewport.height });
|
|
333
|
+
const startTime = Date.now();
|
|
334
|
+
await page.goto(url, { waitUntil: 'networkidle', timeout: 30000 });
|
|
335
|
+
const loadTime = Date.now() - startTime;
|
|
336
|
+
const screenshotPath = path.join(outputDir, `${viewport.name}-${viewport.width}x${viewport.height}.png`);
|
|
337
|
+
await page.screenshot({ path: screenshotPath, fullPage: true });
|
|
338
|
+
results.push({
|
|
339
|
+
viewport,
|
|
340
|
+
screenshotPath,
|
|
341
|
+
loadTime,
|
|
342
|
+
errors,
|
|
343
|
+
});
|
|
344
|
+
}
|
|
345
|
+
catch (error) {
|
|
346
|
+
results.push({
|
|
347
|
+
viewport,
|
|
348
|
+
screenshotPath: '',
|
|
349
|
+
loadTime: 0,
|
|
350
|
+
errors: [error.message],
|
|
351
|
+
});
|
|
352
|
+
}
|
|
353
|
+
finally {
|
|
354
|
+
await page.close();
|
|
355
|
+
}
|
|
356
|
+
}
|
|
357
|
+
return results;
|
|
358
|
+
}
|
|
359
|
+
/**
|
|
360
|
+
* Capture all network requests made during page load
|
|
361
|
+
*/
|
|
362
|
+
async captureNetworkRequests(url) {
|
|
363
|
+
const context = await this.getBrowser();
|
|
364
|
+
const page = await context.newPage();
|
|
365
|
+
const requests = [];
|
|
366
|
+
const requestTimings = new Map();
|
|
367
|
+
page.on('request', (request) => {
|
|
368
|
+
requestTimings.set(request.url(), Date.now());
|
|
369
|
+
});
|
|
370
|
+
page.on('response', (response) => {
|
|
371
|
+
const request = response.request();
|
|
372
|
+
const startTime = requestTimings.get(request.url());
|
|
373
|
+
const duration = startTime ? Date.now() - startTime : null;
|
|
374
|
+
requests.push({
|
|
375
|
+
url: request.url(),
|
|
376
|
+
method: request.method(),
|
|
377
|
+
status: response.status(),
|
|
378
|
+
resourceType: request.resourceType(),
|
|
379
|
+
duration,
|
|
380
|
+
});
|
|
381
|
+
});
|
|
382
|
+
page.on('requestfailed', (request) => {
|
|
383
|
+
const startTime = requestTimings.get(request.url());
|
|
384
|
+
const duration = startTime ? Date.now() - startTime : null;
|
|
385
|
+
requests.push({
|
|
386
|
+
url: request.url(),
|
|
387
|
+
method: request.method(),
|
|
388
|
+
status: null,
|
|
389
|
+
resourceType: request.resourceType(),
|
|
390
|
+
duration,
|
|
391
|
+
});
|
|
392
|
+
});
|
|
393
|
+
try {
|
|
394
|
+
await page.goto(url, { waitUntil: 'networkidle', timeout: 30000 });
|
|
395
|
+
return requests;
|
|
396
|
+
}
|
|
397
|
+
catch (error) {
|
|
398
|
+
// Return what we captured even on error
|
|
399
|
+
return requests;
|
|
400
|
+
}
|
|
401
|
+
finally {
|
|
402
|
+
await page.close();
|
|
403
|
+
}
|
|
404
|
+
}
|
|
405
|
+
/**
|
|
406
|
+
* Run a Playwright test file
|
|
407
|
+
*/
|
|
408
|
+
async runPlaywrightTest(testPath, options) {
|
|
409
|
+
const { exec } = await import('child_process');
|
|
410
|
+
const { promisify } = await import('util');
|
|
411
|
+
const execAsync = promisify(exec);
|
|
412
|
+
const args = ['npx', 'playwright', 'test', testPath];
|
|
413
|
+
if (options?.headed) {
|
|
414
|
+
args.push('--headed');
|
|
415
|
+
}
|
|
416
|
+
if (options?.browser) {
|
|
417
|
+
args.push('--project=' + options.browser);
|
|
418
|
+
}
|
|
419
|
+
if (options?.timeout) {
|
|
420
|
+
args.push('--timeout=' + options.timeout);
|
|
421
|
+
}
|
|
422
|
+
try {
|
|
423
|
+
const { stdout, stderr } = await execAsync(args.join(' '), {
|
|
424
|
+
timeout: options?.timeout || 120000,
|
|
425
|
+
});
|
|
426
|
+
return {
|
|
427
|
+
success: true,
|
|
428
|
+
output: stdout + (stderr ? '\n' + stderr : ''),
|
|
429
|
+
};
|
|
430
|
+
}
|
|
431
|
+
catch (error) {
|
|
432
|
+
return {
|
|
433
|
+
success: false,
|
|
434
|
+
output: error.stdout + (error.stderr ? '\n' + error.stderr : ''),
|
|
435
|
+
};
|
|
436
|
+
}
|
|
437
|
+
}
|
|
55
438
|
}
|
|
56
439
|
//# sourceMappingURL=browser.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"browser.js","sourceRoot":"","sources":["../../src/tools/browser.ts"],"names":[],"mappings":"AAAA,OAAO,SAAsC,MAAM,WAAW,CAAC;AAE/D,MAAM,OAAO,cAAc;IACf,OAAO,GAAmB,IAAI,CAAC;IAE/B,KAAK,CAAC,UAAU;QACpB,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE,CAAC;YAChB,IAAI,CAAC,OAAO,GAAG,MAAM,SAAS,CAAC,MAAM,CAAC;gBAClC,QAAQ,EAAE,IAAI;gBACd,IAAI,EAAE,CAAC,cAAc,EAAE,0BAA0B,CAAC,EAAE,+BAA+B;aACtF,CAAC,CAAC;QACP,CAAC;QACD,OAAO,IAAI,CAAC,OAAO,CAAC;IACxB,CAAC;IAED,KAAK,CAAC,KAAK;QACP,IAAI,IAAI,CAAC,OAAO,EAAE,CAAC;YACf,MAAM,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE,CAAC;YAC3B,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC;QACxB,CAAC;IACL,CAAC;IAED,KAAK,CAAC,cAAc,CAAC,GAAW,EAAE,UAAkB,EAAE,WAAoB,IAAI;QAC1E,MAAM,OAAO,GAAG,MAAM,IAAI,CAAC,UAAU,EAAE,CAAC;QACxC,MAAM,IAAI,GAAG,MAAM,OAA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MAAM,CAAC,CAAC,CAAC,EAAE,CAAC;aACjD,CAAC;QACN,CAAC;QAAC,OAAO,KAAU,EAAE,CAAC;YAClB,OAAO;gBACH,OAAO,EAAE,KAAK;gBACd,MAAM,EAAE,KAAK,CAAC,MAAM,GAAG,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC;aACnE,CAAC;QACN,CAAC;IACL,CAAC;CACJ"}
|
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* AI Test Generator
|
|
3
|
+
*
|
|
4
|
+
* Automatically generates test cases for functions, classes, and modules.
|
|
5
|
+
* Supports multiple testing frameworks: Vitest, Jest, Mocha, pytest, Go test.
|
|
6
|
+
*
|
|
7
|
+
* @module tools/test-generator
|
|
8
|
+
* @since 0.4.0
|
|
9
|
+
*/
|
|
10
|
+
export interface TestCase {
|
|
11
|
+
name: string;
|
|
12
|
+
description: string;
|
|
13
|
+
type: 'unit' | 'integration' | 'edge' | 'boundary' | 'error';
|
|
14
|
+
input?: any;
|
|
15
|
+
expectedOutput?: any;
|
|
16
|
+
assertion?: string;
|
|
17
|
+
}
|
|
18
|
+
export interface FunctionAnalysis {
|
|
19
|
+
name: string;
|
|
20
|
+
params: Array<{
|
|
21
|
+
name: string;
|
|
22
|
+
type?: string;
|
|
23
|
+
optional?: boolean;
|
|
24
|
+
}>;
|
|
25
|
+
returnType?: string;
|
|
26
|
+
isAsync: boolean;
|
|
27
|
+
isExported: boolean;
|
|
28
|
+
complexity: 'low' | 'medium' | 'high';
|
|
29
|
+
dependencies: string[];
|
|
30
|
+
sideEffects: string[];
|
|
31
|
+
}
|
|
32
|
+
export interface ClassAnalysis {
|
|
33
|
+
name: string;
|
|
34
|
+
methods: FunctionAnalysis[];
|
|
35
|
+
properties: Array<{
|
|
36
|
+
name: string;
|
|
37
|
+
type?: string;
|
|
38
|
+
visibility: 'public' | 'private' | 'protected';
|
|
39
|
+
}>;
|
|
40
|
+
constructorMethod?: FunctionAnalysis;
|
|
41
|
+
isExported: boolean;
|
|
42
|
+
}
|
|
43
|
+
export interface ModuleAnalysis {
|
|
44
|
+
filePath: string;
|
|
45
|
+
language: 'typescript' | 'javascript' | 'python' | 'go';
|
|
46
|
+
functions: FunctionAnalysis[];
|
|
47
|
+
classes: ClassAnalysis[];
|
|
48
|
+
exports: string[];
|
|
49
|
+
imports: Array<{
|
|
50
|
+
module: string;
|
|
51
|
+
imports: string[];
|
|
52
|
+
}>;
|
|
53
|
+
}
|
|
54
|
+
export interface GeneratedTest {
|
|
55
|
+
testFilePath: string;
|
|
56
|
+
framework: string;
|
|
57
|
+
content: string;
|
|
58
|
+
testCases: TestCase[];
|
|
59
|
+
coverage: {
|
|
60
|
+
functions: number;
|
|
61
|
+
branches: number;
|
|
62
|
+
lines: number;
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
export interface TestGeneratorConfig {
|
|
66
|
+
framework?: 'vitest' | 'jest' | 'mocha' | 'pytest' | 'go';
|
|
67
|
+
outputDir?: string;
|
|
68
|
+
includeEdgeCases?: boolean;
|
|
69
|
+
includeMocks?: boolean;
|
|
70
|
+
includeTypeChecks?: boolean;
|
|
71
|
+
maxTestsPerFunction?: number;
|
|
72
|
+
style?: 'describe-it' | 'test' | 'flat';
|
|
73
|
+
}
|
|
74
|
+
/**
|
|
75
|
+
* AI-powered test generator that analyzes code and generates comprehensive test suites
|
|
76
|
+
*/
|
|
77
|
+
export declare class TestGenerator {
|
|
78
|
+
private workingDir;
|
|
79
|
+
private testDetector;
|
|
80
|
+
constructor(workingDir?: string);
|
|
81
|
+
/**
|
|
82
|
+
* Analyze a source file to extract testable components
|
|
83
|
+
*/
|
|
84
|
+
analyzeFile(filePath: string): Promise<ModuleAnalysis>;
|
|
85
|
+
/**
|
|
86
|
+
* Analyze JavaScript/TypeScript code
|
|
87
|
+
*/
|
|
88
|
+
private analyzeJSTS;
|
|
89
|
+
/**
|
|
90
|
+
* Analyze Python code
|
|
91
|
+
*/
|
|
92
|
+
private analyzePython;
|
|
93
|
+
/**
|
|
94
|
+
* Analyze Go code
|
|
95
|
+
*/
|
|
96
|
+
private analyzeGo;
|
|
97
|
+
/**
|
|
98
|
+
* Generate test cases for analyzed code
|
|
99
|
+
*/
|
|
100
|
+
generateTests(analysis: ModuleAnalysis, config?: TestGeneratorConfig): Promise<GeneratedTest>;
|
|
101
|
+
/**
|
|
102
|
+
* Generate test cases for a function
|
|
103
|
+
*/
|
|
104
|
+
private generateFunctionTests;
|
|
105
|
+
/**
|
|
106
|
+
* Generate test cases for a class
|
|
107
|
+
*/
|
|
108
|
+
private generateClassTests;
|
|
109
|
+
/**
|
|
110
|
+
* Generate test file content based on framework
|
|
111
|
+
*/
|
|
112
|
+
private generateTestFileContent;
|
|
113
|
+
/**
|
|
114
|
+
* Generate Vitest test content
|
|
115
|
+
*/
|
|
116
|
+
private generateVitestContent;
|
|
117
|
+
/**
|
|
118
|
+
* Generate Jest test content
|
|
119
|
+
*/
|
|
120
|
+
private generateJestContent;
|
|
121
|
+
/**
|
|
122
|
+
* Generate Mocha test content
|
|
123
|
+
*/
|
|
124
|
+
private generateMochaContent;
|
|
125
|
+
/**
|
|
126
|
+
* Generate pytest test content
|
|
127
|
+
*/
|
|
128
|
+
private generatePytestContent;
|
|
129
|
+
/**
|
|
130
|
+
* Generate Go test content
|
|
131
|
+
*/
|
|
132
|
+
private generateGoTestContent;
|
|
133
|
+
private parseJSTSParams;
|
|
134
|
+
private parsePythonParams;
|
|
135
|
+
private parseGoParams;
|
|
136
|
+
private extractClassBody;
|
|
137
|
+
private estimateComplexity;
|
|
138
|
+
private detectDependencies;
|
|
139
|
+
private detectSideEffects;
|
|
140
|
+
private detectFramework;
|
|
141
|
+
private getRelativeImportPath;
|
|
142
|
+
private groupTestCases;
|
|
143
|
+
private generateDefaultArgs;
|
|
144
|
+
private generateInvalidArgs;
|
|
145
|
+
private generateTypeAssertion;
|
|
146
|
+
private generateEdgeCases;
|
|
147
|
+
private convertToPytestAssertion;
|
|
148
|
+
}
|
|
149
|
+
/**
|
|
150
|
+
* Write generated tests to file
|
|
151
|
+
*/
|
|
152
|
+
export declare function writeTestFile(generatedTest: GeneratedTest): Promise<void>;
|
|
153
|
+
/**
|
|
154
|
+
* Quick function to generate and optionally write tests
|
|
155
|
+
*/
|
|
156
|
+
export declare function generateTestsForFile(filePath: string, config?: TestGeneratorConfig, writeToFile?: boolean): Promise<GeneratedTest>;
|
|
157
|
+
//# sourceMappingURL=test-generator.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"test-generator.d.ts","sourceRoot":"","sources":["../../src/tools/test-generator.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAMH,MAAM,WAAW,QAAQ;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,EAAE,MAAM,GAAG,aAAa,GAAG,MAAM,GAAG,UAAU,GAAG,OAAO,CAAC;IAC7D,KAAK,CAAC,EAAE,GAAG,CAAC;IACZ,cAAc,CAAC,EAAE,GAAG,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,CAAC,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,EAAE,OAAO,CAAA;KAAE,CAAC,CAAC;IACnE,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,OAAO,CAAC;IACjB,UAAU,EAAE,OAAO,CAAC;IACpB,UAAU,EAAE,KAAK,GAAG,QAAQ,GAAG,MAAM,CAAC;IACtC,YAAY,EAAE,MAAM,EAAE,CAAC;IACvB,WAAW,EAAE,MAAM,EAAE,CAAC;CACvB;AAED,MAAM,WAAW,aAAa;IAC5B,I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