@supatest/cli 0.0.28 → 0.0.30
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/README.md +35 -9
- package/dist/index.js +237 -8
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -15,9 +15,11 @@ Supatest AI is an AI-powered CLI that helps you write and maintain E2E tests. Us
|
|
|
15
15
|
## Requirements
|
|
16
16
|
|
|
17
17
|
- **Node.js 18+** - [Download Node.js](https://nodejs.org/)
|
|
18
|
-
- **Supatest
|
|
18
|
+
- **Supatest Account** - [Sign up at supatest.ai](https://supatest.ai)
|
|
19
19
|
|
|
20
|
-
##
|
|
20
|
+
## Getting Started
|
|
21
|
+
|
|
22
|
+
### 1. Install
|
|
21
23
|
|
|
22
24
|
```bash
|
|
23
25
|
npm install -g @supatest/cli
|
|
@@ -29,19 +31,43 @@ Or use npx without installing:
|
|
|
29
31
|
npx @supatest/cli
|
|
30
32
|
```
|
|
31
33
|
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
### Interactive Mode
|
|
34
|
+
### 2. Login
|
|
35
35
|
|
|
36
|
-
|
|
36
|
+
Start the CLI and authenticate:
|
|
37
37
|
|
|
38
38
|
```bash
|
|
39
39
|
supatest
|
|
40
40
|
```
|
|
41
41
|
|
|
42
|
-
|
|
42
|
+
```
|
|
43
|
+
> /login
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
This opens your browser to authenticate with your Supatest account.
|
|
47
|
+
|
|
48
|
+
### 3. Setup
|
|
49
|
+
|
|
50
|
+
Check that your environment has the required tools:
|
|
51
|
+
|
|
52
|
+
```
|
|
53
|
+
> /setup
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
This verifies prerequisites like browsers and test frameworks are properly configured.
|
|
57
|
+
|
|
58
|
+
### 4. Discover
|
|
59
|
+
|
|
60
|
+
Scan your project to detect existing test files and configuration:
|
|
61
|
+
|
|
62
|
+
```
|
|
63
|
+
> /discover
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
This helps Supatest understand your test structure so it can work with your existing setup.
|
|
67
|
+
|
|
68
|
+
### 5. Start Testing
|
|
43
69
|
|
|
44
|
-
|
|
70
|
+
Now describe what you want to test:
|
|
45
71
|
|
|
46
72
|
```
|
|
47
73
|
> Write a test for the login flow
|
|
@@ -113,7 +139,7 @@ test:
|
|
|
113
139
|
## Support
|
|
114
140
|
|
|
115
141
|
- [Documentation](https://supatest.ai/docs)
|
|
116
|
-
- [GitHub Issues](https://github.com/
|
|
142
|
+
- [GitHub Issues](https://github.com/supatest-ai/supatest/issues)
|
|
117
143
|
|
|
118
144
|
## License
|
|
119
145
|
|
package/dist/index.js
CHANGED
|
@@ -538,7 +538,7 @@ function getToolDisplayName(toolName) {
|
|
|
538
538
|
};
|
|
539
539
|
return displayNameMap[toolName] || toolName;
|
|
540
540
|
}
|
|
541
|
-
var AVAILABLE_MODELS, DEFAULT_MODEL_ID, DATE_SUFFIX_REGEX, CONTEXT_WINDOWS, util, objectUtil, ZodParsedType, getParsedType, ZodIssueCode, ZodError, errorMap, overrideErrorMap, makeIssue, ParseStatus, INVALID, DIRTY, OK, isAborted, isDirty, isValid, isAsync, errorUtil, ParseInputLazyPath, handleResult, ZodType, cuidRegex, cuid2Regex, ulidRegex, uuidRegex, nanoidRegex, jwtRegex, durationRegex, emailRegex, _emojiRegex, emojiRegex, ipv4Regex, ipv4CidrRegex, ipv6Regex, ipv6CidrRegex, base64Regex, base64urlRegex, dateRegexSource, dateRegex, ZodString, ZodNumber, ZodBigInt, ZodBoolean, ZodDate, ZodSymbol, ZodUndefined, ZodNull, ZodAny, ZodUnknown, ZodNever, ZodVoid, ZodArray, ZodObject, ZodUnion, getDiscriminator, ZodDiscriminatedUnion, ZodIntersection, ZodTuple, ZodRecord, ZodMap, ZodSet, ZodFunction, ZodLazy, ZodLiteral, ZodEnum, ZodNativeEnum, ZodPromise, ZodEffects, ZodOptional, ZodNullable, ZodDefault, ZodCatch, ZodNaN, ZodBranded, ZodPipeline, ZodReadonly, ZodFirstPartyTypeKind, stringType, numberType, booleanType, dateType, unknownType, arrayType, objectType, unionType, discriminatedUnionType, recordType, functionType, lazyType, literalType, enumType, promiseType, coerce, MAX_API_KEY_NAME_LENGTH, apiKeySchema, apiKeyUsageSchema, createApiKeyRequestSchema, apiKeyResponseSchema, apiKeyUsageSummarySchema, genericErrorSchema, validationErrorSchema, feedbackCategorySchema, FEEDBACK_CATEGORIES, createFeedbackSchema, feedbackResponseSchema, listFeedbackQuerySchema, feedbackListResponseSchema, healthMetricSchema, healthMetricDailyItemSchema, healthMetricsWithDailySchema, healthAnalyticsPeriodSchema, healthAnalyticsDailyItemSchema, healthAnalyticsResponseSchema, MAX_TIMEZONE_CHAR_LENGTH, organizationSchema, organizationSettingsSchema, textBlockSchema, toolUseBlockSchema, toolResultBlockSchema, thinkingBlockSchema, imageBlockSchema, contentBlockSchema, sessionSchema, createSessionRequestSchema, updateSessionRequestSchema, messageSchema, createMessageRequestSchema, cliEventSchema, createCLISessionRequestSchema, queryResultSchema, queryTurnSchema, queryContentSchema, queryUsageSchema, querySchema, runStatusSchema, testResultStatusSchema, testOutcomeSchema, attachmentKindSchema, stepCategorySchema, runSummarySchema, ciMetadataSchema, gitMetadataSchema, playwrightConfigSchema, errorInfoSchema, locationSchema, sourceSnippetSchema, runSchema, annotationSchema, testSchema, testResultSchema, baseStepSchema, stepSchema, attachmentSchema, listRunsQuerySchema, listTestsQuerySchema, runsListResponseSchema, runDetailResponseSchema, testsListResponseSchema, testDetailResponseSchema, testHistoryItemSchema, testHistoryResponseSchema, topOffenderSchema, topOffendersResponseSchema, trendPointSchema, trendsResponseSchema, errorCategorySchema, failureClusterSchema, newFailureSchema, runInsightsResponseSchema, FailureCategoryEnum, SelectorTypeEnum, FailureCategoryStatsSchema, FailureCategoriesResponseSchema, FailingSelectorStatsSchema, FailingSelectorsResponseSchema, newFailureItemSchema, newFailuresResponseSchema, flakyTestItemSchema, flakyTestsResponseSchema, slowestTestItemSchema, slowestTestsResponseSchema, runSummaryEmailFailureSchema, runSummaryEmailReportSchema, sendRunReportRequestSchema;
|
|
541
|
+
var AVAILABLE_MODELS, DEFAULT_MODEL_ID, DATE_SUFFIX_REGEX, CONTEXT_WINDOWS, util, objectUtil, ZodParsedType, getParsedType, ZodIssueCode, ZodError, errorMap, overrideErrorMap, makeIssue, ParseStatus, INVALID, DIRTY, OK, isAborted, isDirty, isValid, isAsync, errorUtil, ParseInputLazyPath, handleResult, ZodType, cuidRegex, cuid2Regex, ulidRegex, uuidRegex, nanoidRegex, jwtRegex, durationRegex, emailRegex, _emojiRegex, emojiRegex, ipv4Regex, ipv4CidrRegex, ipv6Regex, ipv6CidrRegex, base64Regex, base64urlRegex, dateRegexSource, dateRegex, ZodString, ZodNumber, ZodBigInt, ZodBoolean, ZodDate, ZodSymbol, ZodUndefined, ZodNull, ZodAny, ZodUnknown, ZodNever, ZodVoid, ZodArray, ZodObject, ZodUnion, getDiscriminator, ZodDiscriminatedUnion, ZodIntersection, ZodTuple, ZodRecord, ZodMap, ZodSet, ZodFunction, ZodLazy, ZodLiteral, ZodEnum, ZodNativeEnum, ZodPromise, ZodEffects, ZodOptional, ZodNullable, ZodDefault, ZodCatch, ZodNaN, ZodBranded, ZodPipeline, ZodReadonly, ZodFirstPartyTypeKind, stringType, numberType, booleanType, dateType, unknownType, arrayType, objectType, unionType, discriminatedUnionType, recordType, functionType, lazyType, literalType, enumType, promiseType, coerce, MAX_API_KEY_NAME_LENGTH, apiKeySchema, apiKeyUsageSchema, createApiKeyRequestSchema, apiKeyResponseSchema, apiKeyUsageSummarySchema, genericErrorSchema, validationErrorSchema, feedbackCategorySchema, FEEDBACK_CATEGORIES, createFeedbackSchema, feedbackResponseSchema, listFeedbackQuerySchema, feedbackListResponseSchema, healthMetricSchema, healthMetricDailyItemSchema, healthMetricsWithDailySchema, healthAnalyticsPeriodSchema, healthAnalyticsDailyItemSchema, healthAnalyticsResponseSchema, MAX_TIMEZONE_CHAR_LENGTH, organizationSchema, organizationSettingsSchema, textBlockSchema, toolUseBlockSchema, toolResultBlockSchema, thinkingBlockSchema, imageBlockSchema, contentBlockSchema, sessionSchema, createSessionRequestSchema, updateSessionRequestSchema, messageSchema, createMessageRequestSchema, cliEventSchema, createCLISessionRequestSchema, queryResultSchema, queryTurnSchema, queryContentSchema, queryUsageSchema, querySchema, runStatusSchema, testResultStatusSchema, testOutcomeSchema, attachmentKindSchema, stepCategorySchema, runSummarySchema, ciMetadataSchema, gitMetadataSchema, playwrightConfigSchema, errorInfoSchema, locationSchema, sourceSnippetSchema, runSchema, annotationSchema, testSchema, testResultSchema, baseStepSchema, stepSchema, attachmentSchema, listRunsQuerySchema, listTestsQuerySchema, runsListResponseSchema, runDetailResponseSchema, testsListResponseSchema, testDetailResponseSchema, testHistoryItemSchema, testHistoryResponseSchema, topOffenderSchema, topOffendersResponseSchema, trendPointSchema, trendsResponseSchema, errorCategorySchema, failureClusterSchema, newFailureSchema, runInsightsResponseSchema, FailureCategoryEnum, SelectorTypeEnum, FailureCategoryStatsSchema, FailureCategoriesResponseSchema, FailingSelectorStatsSchema, FailingSelectorsResponseSchema, newFailureItemSchema, newFailuresResponseSchema, flakyTestItemSchema, flakyTestsResponseSchema, slowestTestItemSchema, slowestTestsResponseSchema, runSummaryEmailFailureSchema, runSummaryEmailReportSchema, sendRunReportRequestSchema, metricWithTrendSchema, weekOverWeekMetricsSchema, ciComputeTimeSchema, investigationCandidateSchema, failureCategoryBreakdownSchema, stabilityTrendSchema, folderStabilitySchema, managerReportSchema, managerReportQuerySchema, sendManagerReportRequestSchema, reportAttachmentLinkSchema, developerReportRegressionSchema, developerReportFlakyTestSchema, developerReportSlowTestSchema, developerRunSummaryReportSchema, executiveReportStatusSchema, executiveMetricSchema, executiveKeyMetricsSchema, executiveTrendPointSchema, executiveTrendsSchema, executiveFlakyOffenderSchema, executiveSlowestOffenderSchema, executiveTopOffendersSchema, executiveReportSchema, executiveReportQuerySchema, sendExecutiveReportRequestSchema;
|
|
542
542
|
var init_shared_es = __esm({
|
|
543
543
|
"../shared/dist/shared.es.mjs"() {
|
|
544
544
|
"use strict";
|
|
@@ -5018,24 +5018,248 @@ var init_shared_es = __esm({
|
|
|
5018
5018
|
startedAt: stringType(),
|
|
5019
5019
|
endedAt: stringType().optional(),
|
|
5020
5020
|
durationMs: numberType(),
|
|
5021
|
-
// Git info
|
|
5022
5021
|
branch: stringType().optional(),
|
|
5023
5022
|
commit: stringType().optional(),
|
|
5024
5023
|
commitMessage: stringType().optional(),
|
|
5025
|
-
// Summary stats
|
|
5026
5024
|
totalTests: numberType(),
|
|
5027
5025
|
passedTests: numberType(),
|
|
5028
5026
|
failedTests: numberType(),
|
|
5029
5027
|
flakyTests: numberType(),
|
|
5030
5028
|
skippedTests: numberType(),
|
|
5031
5029
|
passRate: numberType(),
|
|
5032
|
-
// Top failures
|
|
5033
5030
|
topFailures: arrayType(runSummaryEmailFailureSchema)
|
|
5034
5031
|
});
|
|
5035
5032
|
sendRunReportRequestSchema = objectType({
|
|
5036
5033
|
runId: stringType(),
|
|
5037
5034
|
emails: arrayType(stringType().email())
|
|
5038
5035
|
});
|
|
5036
|
+
metricWithTrendSchema = objectType({
|
|
5037
|
+
current: numberType(),
|
|
5038
|
+
previous: numberType(),
|
|
5039
|
+
change: numberType(),
|
|
5040
|
+
percentChange: numberType().nullable()
|
|
5041
|
+
});
|
|
5042
|
+
weekOverWeekMetricsSchema = objectType({
|
|
5043
|
+
passRate: metricWithTrendSchema,
|
|
5044
|
+
flakyTestCount: metricWithTrendSchema,
|
|
5045
|
+
newFailures: metricWithTrendSchema,
|
|
5046
|
+
totalRuns: metricWithTrendSchema
|
|
5047
|
+
});
|
|
5048
|
+
ciComputeTimeSchema = objectType({
|
|
5049
|
+
failedRunsMs: numberType(),
|
|
5050
|
+
retriedRunsMs: numberType(),
|
|
5051
|
+
totalWastedMs: numberType(),
|
|
5052
|
+
failedRunsHours: numberType(),
|
|
5053
|
+
retriedRunsHours: numberType(),
|
|
5054
|
+
totalWastedHours: numberType()
|
|
5055
|
+
});
|
|
5056
|
+
investigationCandidateSchema = objectType({
|
|
5057
|
+
testId: stringType(),
|
|
5058
|
+
testRunId: stringType(),
|
|
5059
|
+
runId: stringType(),
|
|
5060
|
+
file: stringType(),
|
|
5061
|
+
title: stringType(),
|
|
5062
|
+
flakeCount: numberType(),
|
|
5063
|
+
passRate: numberType(),
|
|
5064
|
+
avgDurationMs: numberType(),
|
|
5065
|
+
ciTimeImpactMs: numberType(),
|
|
5066
|
+
ciTimeImpactHours: numberType(),
|
|
5067
|
+
category: FailureCategoryEnum.nullable(),
|
|
5068
|
+
firstFlakyAt: stringType().nullable()
|
|
5069
|
+
});
|
|
5070
|
+
failureCategoryBreakdownSchema = objectType({
|
|
5071
|
+
category: FailureCategoryEnum,
|
|
5072
|
+
count: numberType(),
|
|
5073
|
+
percentage: numberType()
|
|
5074
|
+
});
|
|
5075
|
+
stabilityTrendSchema = enumType(["improving", "degrading", "stable"]);
|
|
5076
|
+
folderStabilitySchema = objectType({
|
|
5077
|
+
folder: stringType(),
|
|
5078
|
+
passRate: numberType(),
|
|
5079
|
+
previousPassRate: numberType(),
|
|
5080
|
+
trend: stabilityTrendSchema,
|
|
5081
|
+
testCount: numberType(),
|
|
5082
|
+
failureCount: numberType()
|
|
5083
|
+
});
|
|
5084
|
+
managerReportSchema = objectType({
|
|
5085
|
+
period: objectType({
|
|
5086
|
+
start: stringType(),
|
|
5087
|
+
end: stringType(),
|
|
5088
|
+
days: numberType()
|
|
5089
|
+
}),
|
|
5090
|
+
weekOverWeek: weekOverWeekMetricsSchema,
|
|
5091
|
+
ciComputeTime: ciComputeTimeSchema,
|
|
5092
|
+
investigationCandidates: arrayType(investigationCandidateSchema),
|
|
5093
|
+
failureCategories: arrayType(failureCategoryBreakdownSchema),
|
|
5094
|
+
folderStability: arrayType(folderStabilitySchema)
|
|
5095
|
+
});
|
|
5096
|
+
managerReportQuerySchema = objectType({
|
|
5097
|
+
startDate: stringType().regex(
|
|
5098
|
+
/^\d{4}-\d{2}-\d{2}(T\d{2}:\d{2}:\d{2}(\.\d{3})?Z?)?$/,
|
|
5099
|
+
"startDate must be in format YYYY-MM-DD or ISO datetime"
|
|
5100
|
+
),
|
|
5101
|
+
endDate: stringType().regex(
|
|
5102
|
+
/^\d{4}-\d{2}-\d{2}(T\d{2}:\d{2}:\d{2}(\.\d{3})?Z?)?$/,
|
|
5103
|
+
"endDate must be in format YYYY-MM-DD or ISO datetime"
|
|
5104
|
+
)
|
|
5105
|
+
});
|
|
5106
|
+
sendManagerReportRequestSchema = objectType({
|
|
5107
|
+
startDate: stringType(),
|
|
5108
|
+
endDate: stringType(),
|
|
5109
|
+
emails: arrayType(stringType().email())
|
|
5110
|
+
});
|
|
5111
|
+
reportAttachmentLinkSchema = objectType({
|
|
5112
|
+
name: stringType(),
|
|
5113
|
+
kind: attachmentKindSchema,
|
|
5114
|
+
url: stringType().optional()
|
|
5115
|
+
});
|
|
5116
|
+
developerReportRegressionSchema = objectType({
|
|
5117
|
+
testRunId: stringType(),
|
|
5118
|
+
testId: stringType(),
|
|
5119
|
+
title: stringType(),
|
|
5120
|
+
file: stringType(),
|
|
5121
|
+
errorMessage: stringType().nullable(),
|
|
5122
|
+
errorStack: stringType().nullable(),
|
|
5123
|
+
aiSummary: stringType().nullable(),
|
|
5124
|
+
attachments: arrayType(reportAttachmentLinkSchema),
|
|
5125
|
+
lastStableRun: objectType({
|
|
5126
|
+
runId: stringType(),
|
|
5127
|
+
date: stringType(),
|
|
5128
|
+
branch: stringType().optional()
|
|
5129
|
+
}).nullable()
|
|
5130
|
+
});
|
|
5131
|
+
developerReportFlakyTestSchema = objectType({
|
|
5132
|
+
testRunId: stringType(),
|
|
5133
|
+
testId: stringType(),
|
|
5134
|
+
title: stringType(),
|
|
5135
|
+
file: stringType(),
|
|
5136
|
+
passRate: numberType(),
|
|
5137
|
+
category: errorCategorySchema.nullable(),
|
|
5138
|
+
lastPassedRun: objectType({
|
|
5139
|
+
runId: stringType(),
|
|
5140
|
+
date: stringType()
|
|
5141
|
+
}).nullable()
|
|
5142
|
+
});
|
|
5143
|
+
developerReportSlowTestSchema = objectType({
|
|
5144
|
+
testRunId: stringType(),
|
|
5145
|
+
testId: stringType(),
|
|
5146
|
+
title: stringType(),
|
|
5147
|
+
file: stringType(),
|
|
5148
|
+
durationMs: numberType(),
|
|
5149
|
+
historicalAvgMs: numberType(),
|
|
5150
|
+
slowdownFactor: numberType()
|
|
5151
|
+
// how many times slower than average
|
|
5152
|
+
});
|
|
5153
|
+
developerRunSummaryReportSchema = objectType({
|
|
5154
|
+
runId: stringType(),
|
|
5155
|
+
readableId: stringType().optional(),
|
|
5156
|
+
runDetailsUrl: stringType(),
|
|
5157
|
+
startedAt: stringType(),
|
|
5158
|
+
endedAt: stringType().optional(),
|
|
5159
|
+
durationMs: numberType(),
|
|
5160
|
+
branch: stringType().optional(),
|
|
5161
|
+
commit: stringType().optional(),
|
|
5162
|
+
commitMessage: stringType().optional(),
|
|
5163
|
+
// Summary counts
|
|
5164
|
+
totalTests: numberType(),
|
|
5165
|
+
passedTests: numberType(),
|
|
5166
|
+
failedTests: numberType(),
|
|
5167
|
+
flakyTests: numberType(),
|
|
5168
|
+
skippedTests: numberType(),
|
|
5169
|
+
passRate: numberType(),
|
|
5170
|
+
// Sections
|
|
5171
|
+
newRegressions: arrayType(developerReportRegressionSchema),
|
|
5172
|
+
knownFlaky: arrayType(developerReportFlakyTestSchema),
|
|
5173
|
+
slowTests: arrayType(developerReportSlowTestSchema)
|
|
5174
|
+
});
|
|
5175
|
+
executiveReportStatusSchema = enumType([
|
|
5176
|
+
"healthy",
|
|
5177
|
+
"needs_attention",
|
|
5178
|
+
"critical"
|
|
5179
|
+
]);
|
|
5180
|
+
executiveMetricSchema = objectType({
|
|
5181
|
+
/** Current month's value */
|
|
5182
|
+
value: numberType(),
|
|
5183
|
+
/** Previous month's value */
|
|
5184
|
+
previousValue: numberType(),
|
|
5185
|
+
/** Percentage change from previous month (null if previous was 0) */
|
|
5186
|
+
change: numberType().nullable()
|
|
5187
|
+
});
|
|
5188
|
+
executiveKeyMetricsSchema = objectType({
|
|
5189
|
+
/** CI First-Try Pass Rate: COUNT(runs WHERE failed=0 AND flaky=0) / COUNT(runs) */
|
|
5190
|
+
ciFirstTryPassRate: executiveMetricSchema,
|
|
5191
|
+
/** Total Test Pass Rate from health analytics */
|
|
5192
|
+
testPassRate: executiveMetricSchema,
|
|
5193
|
+
/** Count of distinct tests with flaky outcomes */
|
|
5194
|
+
flakyTestCount: executiveMetricSchema,
|
|
5195
|
+
/** CI compute time lost on failed/retried runs in hours */
|
|
5196
|
+
ciComputeLostHours: executiveMetricSchema
|
|
5197
|
+
});
|
|
5198
|
+
executiveTrendPointSchema = objectType({
|
|
5199
|
+
date: stringType(),
|
|
5200
|
+
value: numberType()
|
|
5201
|
+
});
|
|
5202
|
+
executiveTrendsSchema = objectType({
|
|
5203
|
+
/** Daily pass rate values for sparkline */
|
|
5204
|
+
dailyPassRate: arrayType(executiveTrendPointSchema),
|
|
5205
|
+
/** Daily flaky count values for sparkline */
|
|
5206
|
+
dailyFlakyCount: arrayType(executiveTrendPointSchema)
|
|
5207
|
+
});
|
|
5208
|
+
executiveFlakyOffenderSchema = objectType({
|
|
5209
|
+
testId: stringType(),
|
|
5210
|
+
title: stringType(),
|
|
5211
|
+
file: stringType(),
|
|
5212
|
+
/** Number of flaky occurrences */
|
|
5213
|
+
flakyCount: numberType(),
|
|
5214
|
+
/** CI time impact in hours */
|
|
5215
|
+
ciTimeImpactHours: numberType()
|
|
5216
|
+
});
|
|
5217
|
+
executiveSlowestOffenderSchema = objectType({
|
|
5218
|
+
testId: stringType(),
|
|
5219
|
+
title: stringType(),
|
|
5220
|
+
file: stringType(),
|
|
5221
|
+
/** Average duration in milliseconds */
|
|
5222
|
+
avgDurationMs: numberType(),
|
|
5223
|
+
/** Trend percentage change from previous period (null if no previous data) */
|
|
5224
|
+
trend: numberType().nullable()
|
|
5225
|
+
});
|
|
5226
|
+
executiveTopOffendersSchema = objectType({
|
|
5227
|
+
/** Top 3 most flaky tests with CI time impact */
|
|
5228
|
+
mostFlaky: arrayType(executiveFlakyOffenderSchema),
|
|
5229
|
+
/** Top 3 slowest tests with trend */
|
|
5230
|
+
slowest: arrayType(executiveSlowestOffenderSchema)
|
|
5231
|
+
});
|
|
5232
|
+
executiveReportSchema = objectType({
|
|
5233
|
+
/** Month in format YYYY-MM */
|
|
5234
|
+
month: stringType(),
|
|
5235
|
+
/** When the report was generated */
|
|
5236
|
+
generatedAt: stringType(),
|
|
5237
|
+
/** URL to view full report in dashboard */
|
|
5238
|
+
reportUrl: stringType(),
|
|
5239
|
+
/** Overall status: healthy, needs_attention, or critical */
|
|
5240
|
+
status: executiveReportStatusSchema,
|
|
5241
|
+
/** 4 key metrics with month-over-month comparison */
|
|
5242
|
+
keyMetrics: executiveKeyMetricsSchema,
|
|
5243
|
+
/** 30-day trend data for sparklines */
|
|
5244
|
+
trends: executiveTrendsSchema,
|
|
5245
|
+
/** Top offenders (most flaky and slowest tests) */
|
|
5246
|
+
topOffenders: executiveTopOffendersSchema,
|
|
5247
|
+
/** Auto-generated signal messages based on thresholds */
|
|
5248
|
+
signals: arrayType(stringType())
|
|
5249
|
+
});
|
|
5250
|
+
executiveReportQuerySchema = objectType({
|
|
5251
|
+
month: stringType().regex(
|
|
5252
|
+
/^\d{4}-\d{2}$/,
|
|
5253
|
+
"month must be in format YYYY-MM"
|
|
5254
|
+
)
|
|
5255
|
+
});
|
|
5256
|
+
sendExecutiveReportRequestSchema = objectType({
|
|
5257
|
+
month: stringType().regex(
|
|
5258
|
+
/^\d{4}-\d{2}$/,
|
|
5259
|
+
"month must be in format YYYY-MM"
|
|
5260
|
+
),
|
|
5261
|
+
emails: arrayType(stringType().email())
|
|
5262
|
+
});
|
|
5039
5263
|
}
|
|
5040
5264
|
});
|
|
5041
5265
|
|
|
@@ -5072,7 +5296,9 @@ function getPlaywrightVersion() {
|
|
|
5072
5296
|
try {
|
|
5073
5297
|
const result = spawnSync("npx", ["playwright", "--version"], {
|
|
5074
5298
|
encoding: "utf-8",
|
|
5075
|
-
stdio: ["ignore", "pipe", "ignore"]
|
|
5299
|
+
stdio: ["ignore", "pipe", "ignore"],
|
|
5300
|
+
shell: true
|
|
5301
|
+
// Required for Windows where npx is npx.cmd
|
|
5076
5302
|
});
|
|
5077
5303
|
if (result.status === 0 && result.stdout) {
|
|
5078
5304
|
return result.stdout.trim().replace("Version ", "");
|
|
@@ -5140,7 +5366,9 @@ function installChromium() {
|
|
|
5140
5366
|
console.log("");
|
|
5141
5367
|
try {
|
|
5142
5368
|
const result = spawnSync("npx", ["playwright", "install", "chromium"], {
|
|
5143
|
-
stdio: "inherit"
|
|
5369
|
+
stdio: "inherit",
|
|
5370
|
+
shell: true
|
|
5371
|
+
// Required for Windows where npx is npx.cmd
|
|
5144
5372
|
});
|
|
5145
5373
|
if (result.status === 0) {
|
|
5146
5374
|
return {
|
|
@@ -5294,7 +5522,7 @@ var CLI_VERSION;
|
|
|
5294
5522
|
var init_version = __esm({
|
|
5295
5523
|
"src/version.ts"() {
|
|
5296
5524
|
"use strict";
|
|
5297
|
-
CLI_VERSION = "0.0.
|
|
5525
|
+
CLI_VERSION = "0.0.30";
|
|
5298
5526
|
}
|
|
5299
5527
|
});
|
|
5300
5528
|
|
|
@@ -8317,7 +8545,8 @@ function openBrowser(url) {
|
|
|
8317
8545
|
default:
|
|
8318
8546
|
command = "xdg-open";
|
|
8319
8547
|
}
|
|
8320
|
-
|
|
8548
|
+
const options = { detached: true, stdio: "ignore", shell: os3 === "win32" };
|
|
8549
|
+
spawn2(command, [url], options).unref();
|
|
8321
8550
|
}
|
|
8322
8551
|
function startCallbackServer(port, expectedState) {
|
|
8323
8552
|
return new Promise((resolve2, reject) => {
|