@empiricalrun/playwright-utils 0.57.0 → 0.58.0
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/CHANGELOG.md
CHANGED
package/dist/config/index.js
CHANGED
|
@@ -39,7 +39,6 @@ function getReporters() {
|
|
|
39
39
|
if (process.env.HAS_SHARDING && !process.env.SHARD_INDEX) {
|
|
40
40
|
throw new Error("Invalid env variables: HAS_SHARDING needs SHARD_INDEX");
|
|
41
41
|
}
|
|
42
|
-
const useIncrementalReporter = process.env.SPOT_INSTANCE === "true";
|
|
43
42
|
const middle = process.env.HAS_SHARDING
|
|
44
43
|
? [
|
|
45
44
|
[
|
|
@@ -49,6 +48,14 @@ function getReporters() {
|
|
|
49
48
|
fileName: `report-${process.env.SHARD_INDEX}.zip`,
|
|
50
49
|
},
|
|
51
50
|
],
|
|
51
|
+
// Salvage path for a blob report that never gets written: on SIGINT the
|
|
52
|
+
// blob reporter can be cut off mid-run, and this one has already been
|
|
53
|
+
// streaming events to disk. It is only useful where a merge step exists
|
|
54
|
+
// to consume its zip, which is exactly where the blob reporter runs -
|
|
55
|
+
// so it is gated on sharding rather than on the run being on spot.
|
|
56
|
+
[
|
|
57
|
+
"./node_modules/@empiricalrun/playwright-utils/dist/reporter/incremental-blob-reporter.js",
|
|
58
|
+
],
|
|
52
59
|
]
|
|
53
60
|
: [
|
|
54
61
|
["html", { open: "never" }],
|
|
@@ -57,13 +64,6 @@ function getReporters() {
|
|
|
57
64
|
return [
|
|
58
65
|
["list"],
|
|
59
66
|
...middle,
|
|
60
|
-
...(useIncrementalReporter
|
|
61
|
-
? [
|
|
62
|
-
[
|
|
63
|
-
"./node_modules/@empiricalrun/playwright-utils/dist/reporter/incremental-blob-reporter.js",
|
|
64
|
-
],
|
|
65
|
-
]
|
|
66
|
-
: []),
|
|
67
67
|
[
|
|
68
68
|
"./node_modules/@empiricalrun/playwright-utils/dist/reporter/empirical-reporter.js",
|
|
69
69
|
],
|
|
@@ -1434,6 +1434,26 @@ export interface paths {
|
|
|
1434
1434
|
patch?: never;
|
|
1435
1435
|
trace?: never;
|
|
1436
1436
|
};
|
|
1437
|
+
"/api/beta/alerts/events": {
|
|
1438
|
+
parameters: {
|
|
1439
|
+
query?: never;
|
|
1440
|
+
header?: never;
|
|
1441
|
+
path?: never;
|
|
1442
|
+
cookie?: never;
|
|
1443
|
+
};
|
|
1444
|
+
/**
|
|
1445
|
+
* 🧪 List recent alert events
|
|
1446
|
+
* @description Returns the scoped project's alert opened and resolved events, newest first.
|
|
1447
|
+
*/
|
|
1448
|
+
get: operations["listRecentAlertEvents"];
|
|
1449
|
+
put?: never;
|
|
1450
|
+
post?: never;
|
|
1451
|
+
delete?: never;
|
|
1452
|
+
options?: never;
|
|
1453
|
+
head?: never;
|
|
1454
|
+
patch?: never;
|
|
1455
|
+
trace?: never;
|
|
1456
|
+
};
|
|
1437
1457
|
"/api/v1/telemetry/overlay-dismissals": {
|
|
1438
1458
|
parameters: {
|
|
1439
1459
|
query?: never;
|
|
@@ -3549,6 +3569,46 @@ export interface paths {
|
|
|
3549
3569
|
patch?: never;
|
|
3550
3570
|
trace?: never;
|
|
3551
3571
|
};
|
|
3572
|
+
"/api/invoices/org/{id}/razorpay-order": {
|
|
3573
|
+
parameters: {
|
|
3574
|
+
query?: never;
|
|
3575
|
+
header?: never;
|
|
3576
|
+
path?: never;
|
|
3577
|
+
cookie?: never;
|
|
3578
|
+
};
|
|
3579
|
+
get?: never;
|
|
3580
|
+
put?: never;
|
|
3581
|
+
/**
|
|
3582
|
+
* 🛡️ Create a Razorpay order to pay an INR invoice
|
|
3583
|
+
* @description Creates a Razorpay order for the outstanding amount of one of the scoped project's org's sent INR invoices. The browser opens Razorpay Standard Checkout with the returned order and key ids; the resulting payment is confirmed via the razorpay-verify endpoint. Orders are not stored; a new one is created per attempt.
|
|
3584
|
+
*/
|
|
3585
|
+
post: operations["createInvoiceRazorpayOrder"];
|
|
3586
|
+
delete?: never;
|
|
3587
|
+
options?: never;
|
|
3588
|
+
head?: never;
|
|
3589
|
+
patch?: never;
|
|
3590
|
+
trace?: never;
|
|
3591
|
+
};
|
|
3592
|
+
"/api/invoices/org/{id}/razorpay-verify": {
|
|
3593
|
+
parameters: {
|
|
3594
|
+
query?: never;
|
|
3595
|
+
header?: never;
|
|
3596
|
+
path?: never;
|
|
3597
|
+
cookie?: never;
|
|
3598
|
+
};
|
|
3599
|
+
get?: never;
|
|
3600
|
+
put?: never;
|
|
3601
|
+
/**
|
|
3602
|
+
* 🛡️ Verify a Razorpay payment and settle the invoice
|
|
3603
|
+
* @description Verifies the Standard Checkout signature for a payment on one of the scoped project's org's sent invoices, cross-checks the order and payment against Razorpay's API, and mirrors the payment onto the invoice (paid status, paid amount, payment ref). Idempotent per payment: redelivering a settled payment is a no-op.
|
|
3604
|
+
*/
|
|
3605
|
+
post: operations["verifyInvoiceRazorpayPayment"];
|
|
3606
|
+
delete?: never;
|
|
3607
|
+
options?: never;
|
|
3608
|
+
head?: never;
|
|
3609
|
+
patch?: never;
|
|
3610
|
+
trace?: never;
|
|
3611
|
+
};
|
|
3552
3612
|
"/api/invoices/org/{id}/tax-invoice/download": {
|
|
3553
3613
|
parameters: {
|
|
3554
3614
|
query?: never;
|
|
@@ -5292,6 +5352,11 @@ export interface components {
|
|
|
5292
5352
|
has_tax_invoice: boolean;
|
|
5293
5353
|
/** @description Whether this invoice can be paid online (unpaid and in a supported currency). */
|
|
5294
5354
|
payable: boolean;
|
|
5355
|
+
/**
|
|
5356
|
+
* @description Which provider pays this invoice's currency (USD via Dodo checkout sessions, INR via Razorpay Standard Checkout), or null if none does. Drives the Pay button's checkout flow.
|
|
5357
|
+
* @enum {string|null}
|
|
5358
|
+
*/
|
|
5359
|
+
payment_provider: "dodo" | "razorpay" | null;
|
|
5295
5360
|
/** @description Whether an unpaid invoice is past its due date plus the reminder grace period. Always false for paid invoices. */
|
|
5296
5361
|
past_reminder_date: boolean;
|
|
5297
5362
|
};
|
|
@@ -5320,6 +5385,40 @@ export interface components {
|
|
|
5320
5385
|
*/
|
|
5321
5386
|
return_url: string;
|
|
5322
5387
|
};
|
|
5388
|
+
InvoiceRazorpayOrderResponse: {
|
|
5389
|
+
/** @description Response payload. */
|
|
5390
|
+
data: {
|
|
5391
|
+
/** @description Razorpay order ID. */
|
|
5392
|
+
order_id: string;
|
|
5393
|
+
/** @description Order amount in paise (the outstanding amount). */
|
|
5394
|
+
amount: number;
|
|
5395
|
+
/** @description Order currency (INR). */
|
|
5396
|
+
currency: string;
|
|
5397
|
+
/** @description Publishable Razorpay key id the browser passes to Standard Checkout. */
|
|
5398
|
+
key_id: string;
|
|
5399
|
+
/** @description Org billing email, for checkout prefill. */
|
|
5400
|
+
billing_email: string | null;
|
|
5401
|
+
/** @description Org name, for checkout prefill. */
|
|
5402
|
+
org_name: string | null;
|
|
5403
|
+
};
|
|
5404
|
+
};
|
|
5405
|
+
VerifyInvoiceRazorpayPaymentResponse: {
|
|
5406
|
+
/** @description Response payload. */
|
|
5407
|
+
data: {
|
|
5408
|
+
/** @description Invoice paid status after settling. */
|
|
5409
|
+
paid_status: string;
|
|
5410
|
+
/** @description Total settled amount in paise after this payment. */
|
|
5411
|
+
paid_minor: number;
|
|
5412
|
+
};
|
|
5413
|
+
};
|
|
5414
|
+
VerifyInvoiceRazorpayPaymentRequest: {
|
|
5415
|
+
/** @description Order id returned by razorpay-order. */
|
|
5416
|
+
razorpay_order_id: string;
|
|
5417
|
+
/** @description Payment id from the checkout success handler. */
|
|
5418
|
+
razorpay_payment_id: string;
|
|
5419
|
+
/** @description Checkout signature: hex HMAC-SHA256 of `order_id|payment_id`. */
|
|
5420
|
+
razorpay_signature: string;
|
|
5421
|
+
};
|
|
5323
5422
|
InvoiceListResponse: {
|
|
5324
5423
|
/** @description The page of invoices. */
|
|
5325
5424
|
data: {
|
|
@@ -11498,6 +11597,20 @@ export interface components {
|
|
|
11498
11597
|
/** @description Test tags. */
|
|
11499
11598
|
tags: string[];
|
|
11500
11599
|
} | null;
|
|
11600
|
+
/** @description The most-recently-seen failure group this alert's test is currently attached to; null when the test is in no group. */
|
|
11601
|
+
failure_group: {
|
|
11602
|
+
/** @description Failure group ID. */
|
|
11603
|
+
id: string;
|
|
11604
|
+
/** @description Human-readable group label. */
|
|
11605
|
+
label: string;
|
|
11606
|
+
/**
|
|
11607
|
+
* @description Group lifecycle status.
|
|
11608
|
+
* @enum {string}
|
|
11609
|
+
*/
|
|
11610
|
+
status: "open" | "resolved";
|
|
11611
|
+
/** @description True when a membership sighting cites a run in the alert's outcome window. */
|
|
11612
|
+
seen_in_window: boolean;
|
|
11613
|
+
} | null;
|
|
11501
11614
|
};
|
|
11502
11615
|
AlertRunOutcome: {
|
|
11503
11616
|
/** @description The evaluated test run. */
|
|
@@ -11508,6 +11621,31 @@ export interface components {
|
|
|
11508
11621
|
*/
|
|
11509
11622
|
status: "pass" | "fail";
|
|
11510
11623
|
};
|
|
11624
|
+
RecentAlertEventListResponse: {
|
|
11625
|
+
data: {
|
|
11626
|
+
events: components["schemas"]["RecentAlertEvent"][];
|
|
11627
|
+
};
|
|
11628
|
+
pagination: components["schemas"]["Pagination"];
|
|
11629
|
+
};
|
|
11630
|
+
RecentAlertEvent: {
|
|
11631
|
+
id: number;
|
|
11632
|
+
alert_id: number;
|
|
11633
|
+
/** @enum {string} */
|
|
11634
|
+
type: "opened" | "resolved";
|
|
11635
|
+
test_run_id: number | null;
|
|
11636
|
+
environment_id: number;
|
|
11637
|
+
pw_test_id: string;
|
|
11638
|
+
created_at: string;
|
|
11639
|
+
test_case: components["schemas"]["AlertTestCase"];
|
|
11640
|
+
};
|
|
11641
|
+
AlertTestCase: {
|
|
11642
|
+
/** @description Human-readable test name. */
|
|
11643
|
+
name: string;
|
|
11644
|
+
/** @description Test file path. */
|
|
11645
|
+
file_path: string;
|
|
11646
|
+
/** @description Test tags. */
|
|
11647
|
+
tags: string[];
|
|
11648
|
+
} | null;
|
|
11511
11649
|
AlertDetailResponse: {
|
|
11512
11650
|
/** @description Response payload. */
|
|
11513
11651
|
data: {
|
|
@@ -11553,8 +11691,24 @@ export interface components {
|
|
|
11553
11691
|
/** @description Test tags. */
|
|
11554
11692
|
tags: string[];
|
|
11555
11693
|
} | null;
|
|
11694
|
+
/** @description The most-recently-seen failure group this alert's test is currently attached to; null when the test is in no group. */
|
|
11695
|
+
failure_group: {
|
|
11696
|
+
/** @description Failure group ID. */
|
|
11697
|
+
id: string;
|
|
11698
|
+
/** @description Human-readable group label. */
|
|
11699
|
+
label: string;
|
|
11700
|
+
/**
|
|
11701
|
+
* @description Group lifecycle status.
|
|
11702
|
+
* @enum {string}
|
|
11703
|
+
*/
|
|
11704
|
+
status: "open" | "resolved";
|
|
11705
|
+
/** @description True when a membership sighting cites a run in the alert's outcome window. */
|
|
11706
|
+
seen_in_window: boolean;
|
|
11707
|
+
} | null;
|
|
11556
11708
|
/** @description The alert's lifecycle events, oldest first. */
|
|
11557
11709
|
events: components["schemas"]["AlertEvent"][];
|
|
11710
|
+
/** @description Failure groups the alerting test is currently attached to, most recently seen first; empty when the test is in no group. */
|
|
11711
|
+
related_failure_groups: components["schemas"]["AlertRelatedFailureGroup"][];
|
|
11558
11712
|
};
|
|
11559
11713
|
AlertEvent: {
|
|
11560
11714
|
/** @description Alert event ID. */
|
|
@@ -11569,6 +11723,26 @@ export interface components {
|
|
|
11569
11723
|
/** @description ISO 8601 timestamp of the event. */
|
|
11570
11724
|
created_at: string;
|
|
11571
11725
|
};
|
|
11726
|
+
AlertRelatedFailureGroup: {
|
|
11727
|
+
/** @description Failure group ID. */
|
|
11728
|
+
id: string;
|
|
11729
|
+
/** @description Human-readable group label. */
|
|
11730
|
+
label: string;
|
|
11731
|
+
/**
|
|
11732
|
+
* @description Failure-mode classification.
|
|
11733
|
+
* @enum {string}
|
|
11734
|
+
*/
|
|
11735
|
+
type: "app" | "test" | "unknown";
|
|
11736
|
+
/**
|
|
11737
|
+
* @description Group lifecycle status.
|
|
11738
|
+
* @enum {string}
|
|
11739
|
+
*/
|
|
11740
|
+
status: "open" | "resolved";
|
|
11741
|
+
/** @description ISO 8601 timestamp the group was last seen. */
|
|
11742
|
+
last_seen_at: string;
|
|
11743
|
+
/** @description True when a membership sighting for this test cites one of the runs in the alert's outcome window (deterministic test × env × run mapping). False = the test is attached to the group in this environment, but not via the runs this alert counted. */
|
|
11744
|
+
seen_in_window: boolean;
|
|
11745
|
+
};
|
|
11572
11746
|
WebhookListResponse: {
|
|
11573
11747
|
/** @description Response payload. */
|
|
11574
11748
|
data: {
|
|
@@ -16029,6 +16203,38 @@ export interface operations {
|
|
|
16029
16203
|
};
|
|
16030
16204
|
};
|
|
16031
16205
|
};
|
|
16206
|
+
listRecentAlertEvents: {
|
|
16207
|
+
parameters: {
|
|
16208
|
+
query?: {
|
|
16209
|
+
page?: number;
|
|
16210
|
+
per_page?: number;
|
|
16211
|
+
};
|
|
16212
|
+
header?: never;
|
|
16213
|
+
path?: never;
|
|
16214
|
+
cookie?: never;
|
|
16215
|
+
};
|
|
16216
|
+
requestBody?: never;
|
|
16217
|
+
responses: {
|
|
16218
|
+
/** @description Paginated alert opened and resolved events. */
|
|
16219
|
+
200: {
|
|
16220
|
+
headers: {
|
|
16221
|
+
[name: string]: unknown;
|
|
16222
|
+
};
|
|
16223
|
+
content: {
|
|
16224
|
+
"application/json": components["schemas"]["RecentAlertEventListResponse"];
|
|
16225
|
+
};
|
|
16226
|
+
};
|
|
16227
|
+
/** @description Invalid request or missing project scope. */
|
|
16228
|
+
400: {
|
|
16229
|
+
headers: {
|
|
16230
|
+
[name: string]: unknown;
|
|
16231
|
+
};
|
|
16232
|
+
content: {
|
|
16233
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
16234
|
+
};
|
|
16235
|
+
};
|
|
16236
|
+
};
|
|
16237
|
+
};
|
|
16032
16238
|
getOverlayDismissalSummary: {
|
|
16033
16239
|
parameters: {
|
|
16034
16240
|
query?: {
|
|
@@ -21612,6 +21818,110 @@ export interface operations {
|
|
|
21612
21818
|
};
|
|
21613
21819
|
};
|
|
21614
21820
|
};
|
|
21821
|
+
createInvoiceRazorpayOrder: {
|
|
21822
|
+
parameters: {
|
|
21823
|
+
query?: never;
|
|
21824
|
+
header?: never;
|
|
21825
|
+
path: {
|
|
21826
|
+
/** @description Invoice ID. */
|
|
21827
|
+
id: string;
|
|
21828
|
+
};
|
|
21829
|
+
cookie?: never;
|
|
21830
|
+
};
|
|
21831
|
+
requestBody?: never;
|
|
21832
|
+
responses: {
|
|
21833
|
+
/** @description The Razorpay order. */
|
|
21834
|
+
200: {
|
|
21835
|
+
headers: {
|
|
21836
|
+
[name: string]: unknown;
|
|
21837
|
+
};
|
|
21838
|
+
content: {
|
|
21839
|
+
"application/json": components["schemas"]["InvoiceRazorpayOrderResponse"];
|
|
21840
|
+
};
|
|
21841
|
+
};
|
|
21842
|
+
/** @description Invalid request, unsupported currency, or Razorpay not configured. */
|
|
21843
|
+
400: {
|
|
21844
|
+
headers: {
|
|
21845
|
+
[name: string]: unknown;
|
|
21846
|
+
};
|
|
21847
|
+
content: {
|
|
21848
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
21849
|
+
};
|
|
21850
|
+
};
|
|
21851
|
+
/** @description Invoice not found. */
|
|
21852
|
+
404: {
|
|
21853
|
+
headers: {
|
|
21854
|
+
[name: string]: unknown;
|
|
21855
|
+
};
|
|
21856
|
+
content: {
|
|
21857
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
21858
|
+
};
|
|
21859
|
+
};
|
|
21860
|
+
/** @description Invoice has no outstanding amount. */
|
|
21861
|
+
409: {
|
|
21862
|
+
headers: {
|
|
21863
|
+
[name: string]: unknown;
|
|
21864
|
+
};
|
|
21865
|
+
content: {
|
|
21866
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
21867
|
+
};
|
|
21868
|
+
};
|
|
21869
|
+
};
|
|
21870
|
+
};
|
|
21871
|
+
verifyInvoiceRazorpayPayment: {
|
|
21872
|
+
parameters: {
|
|
21873
|
+
query?: never;
|
|
21874
|
+
header?: never;
|
|
21875
|
+
path: {
|
|
21876
|
+
/** @description Invoice ID. */
|
|
21877
|
+
id: string;
|
|
21878
|
+
};
|
|
21879
|
+
cookie?: never;
|
|
21880
|
+
};
|
|
21881
|
+
requestBody?: {
|
|
21882
|
+
content: {
|
|
21883
|
+
"application/json": components["schemas"]["VerifyInvoiceRazorpayPaymentRequest"];
|
|
21884
|
+
};
|
|
21885
|
+
};
|
|
21886
|
+
responses: {
|
|
21887
|
+
/** @description The settled payment state. */
|
|
21888
|
+
200: {
|
|
21889
|
+
headers: {
|
|
21890
|
+
[name: string]: unknown;
|
|
21891
|
+
};
|
|
21892
|
+
content: {
|
|
21893
|
+
"application/json": components["schemas"]["VerifyInvoiceRazorpayPaymentResponse"];
|
|
21894
|
+
};
|
|
21895
|
+
};
|
|
21896
|
+
/** @description Invalid request, signature mismatch, order/invoice mismatch, or Razorpay not configured. */
|
|
21897
|
+
400: {
|
|
21898
|
+
headers: {
|
|
21899
|
+
[name: string]: unknown;
|
|
21900
|
+
};
|
|
21901
|
+
content: {
|
|
21902
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
21903
|
+
};
|
|
21904
|
+
};
|
|
21905
|
+
/** @description Invoice not found. */
|
|
21906
|
+
404: {
|
|
21907
|
+
headers: {
|
|
21908
|
+
[name: string]: unknown;
|
|
21909
|
+
};
|
|
21910
|
+
content: {
|
|
21911
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
21912
|
+
};
|
|
21913
|
+
};
|
|
21914
|
+
/** @description Payment not in a settled state. */
|
|
21915
|
+
409: {
|
|
21916
|
+
headers: {
|
|
21917
|
+
[name: string]: unknown;
|
|
21918
|
+
};
|
|
21919
|
+
content: {
|
|
21920
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
21921
|
+
};
|
|
21922
|
+
};
|
|
21923
|
+
};
|
|
21924
|
+
};
|
|
21615
21925
|
downloadOrgInvoiceTaxInvoice: {
|
|
21616
21926
|
parameters: {
|
|
21617
21927
|
query?: never;
|