@threenative/playtest 0.3.11 → 0.3.13
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/dist/capture.d.ts +1 -1
- package/dist/{diagnostics-BKg7C6Lf.d.ts → diagnostics-0g-Uyvds.d.ts} +2 -12
- package/dist/index.d.ts +14 -5
- package/dist/index.js +3625 -3796
- package/dist/protocol.d.ts +73 -1
- package/dist/protocol.js +13 -1
- package/dist/runner/cli.d.ts +3 -3
- package/dist/runner/cli.js +6946 -6968
- package/dist/runner/index.d.ts +231 -204
- package/dist/runner/index.js +10038 -10105
- package/dist/{schema-base-B26KSBoa.d.ts → schema-base-D8wNuOLE.d.ts} +26 -27
- package/dist/{shared-Dg-3kiU8.d.ts → shared-CRg0jlDU.d.ts} +11 -3
- package/package.json +2 -2
package/dist/runner/index.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { IPlaytestSetupRequest, JsonValue, IPlaytestBridgeDescription, IPlaytestBridgeReady, IPlaytestSampleRequest, IPlaytestObservationSnapshot } from '../protocol.js';
|
|
2
|
-
import { e as IPlaytestScenario, f as IPlaytestArtifactRequest,
|
|
3
|
-
import { q as IPlaytestSetupApplication, p as IPlaytestProtocolDiagnostic, o as IPlaytestObservations, n as IPlaytestFramebufferCoverageObservation, f as IPlaytestCaptureProvenance, h as IPlaytestDeviceMetricsObservation, b as IPlaytestDiagnostic, E as
|
|
4
|
-
export { K as AdbAndroidDriver, L as IAndroidDriverOptions, M as IAndroidLifecycleOperation, N as IAndroidTouchViewport, O as IPlaytestDeviceLifecycleObservation, Q as IPlaytestDeviceLifecyclePhase, R as IPlaytestDeviceLifecyclePhysics, S as IPlaytestDeviceLifecycleSteps, T as androidTouchBatches, U as discoverAdb, V as keyboardIsShown, W as parseAndroidConsole, X as parseAndroidTouchViewport, Y as rotatedTouchPosition, Z as tapCommand, _ as touchPositionForViewport, $ as touchRotationFromWindowDump, a0 as viewportPresentationCommands, a1 as viewportPresentationObserved, a2 as viewportRestoreCommands } from '../diagnostics-
|
|
2
|
+
import { e as IPlaytestScenario, f as IPlaytestArtifactRequest, l as IPlaytestPointer } from '../schema-base-D8wNuOLE.js';
|
|
3
|
+
import { q as IPlaytestSetupApplication, p as IPlaytestProtocolDiagnostic, o as IPlaytestObservations, n as IPlaytestFramebufferCoverageObservation, f as IPlaytestCaptureProvenance, h as IPlaytestDeviceMetricsObservation, b as IPlaytestDiagnostic, E as IAndroidDriver, F as IAndroidAppState, G as IAndroidPointer, J as IAndroidPointerInjection } from '../diagnostics-0g-Uyvds.js';
|
|
4
|
+
export { K as AdbAndroidDriver, L as IAndroidDriverOptions, M as IAndroidLifecycleOperation, N as IAndroidTouchViewport, O as IPlaytestDeviceLifecycleObservation, Q as IPlaytestDeviceLifecyclePhase, R as IPlaytestDeviceLifecyclePhysics, S as IPlaytestDeviceLifecycleSteps, T as androidTouchBatches, U as discoverAdb, V as keyboardIsShown, W as parseAndroidConsole, X as parseAndroidTouchViewport, Y as rotatedTouchPosition, Z as tapCommand, _ as touchPositionForViewport, $ as touchRotationFromWindowDump, a0 as viewportPresentationCommands, a1 as viewportPresentationObserved, a2 as viewportRestoreCommands } from '../diagnostics-0g-Uyvds.js';
|
|
5
5
|
import { Page } from 'playwright';
|
|
6
|
-
import { I as IStandalonePlaytestConfig, b as IRunnerConsoleEntry, c as ILabeledPlaytestSample, d as IMovementSampleInterval, a as IStandalonePlaytestReport } from '../shared-
|
|
7
|
-
export { e as IPlaytestFlagHelp, f as IPlaytestServerConfig, g as IRunStepSamples, M as ManagedServerError, P as PLAYTEST_FLAGS, h as PlaytestCliUsageError, i as advanceFixedStep, j as captureVisualSurface, k as failedDiagnosticsAssertion, l as formatUsage, p as parseStandalonePlaytestArgs, m as playtestStepDrivesMovement, w as withScenarioClock } from '../shared-
|
|
6
|
+
import { I as IStandalonePlaytestConfig, b as IRunnerConsoleEntry, c as ILabeledPlaytestSample, d as IMovementSampleInterval, a as IStandalonePlaytestReport } from '../shared-CRg0jlDU.js';
|
|
7
|
+
export { e as IPlaytestFlagHelp, f as IPlaytestServerConfig, g as IRunStepSamples, M as ManagedServerError, P as PLAYTEST_FLAGS, h as PlaytestCliUsageError, i as advanceFixedStep, j as captureVisualSurface, k as failedDiagnosticsAssertion, l as formatUsage, p as parseStandalonePlaytestArgs, m as playtestStepDrivesMovement, w as withScenarioClock } from '../shared-CRg0jlDU.js';
|
|
8
8
|
import { ChildProcess } from 'node:child_process';
|
|
9
9
|
|
|
10
10
|
/** The only seam between assertion orchestration and an application bridge. */
|
|
@@ -241,6 +241,225 @@ interface IBrowserPointerChange {
|
|
|
241
241
|
}
|
|
242
242
|
declare function reconcileBrowserPointers(previous: ReadonlyMap<number, Required<IPlaytestPointer>>, next: readonly IPlaytestPointer[]): IBrowserPointerChange[];
|
|
243
243
|
|
|
244
|
+
/** Shared parser and aggregation for browser pipeline censuses and native pipeline markers. */
|
|
245
|
+
declare const PIPELINE_CAPTURE_VERSION: 1;
|
|
246
|
+
declare const PIPELINE_EVENT_MARKER = "TN_PIPELINE_EVENT:";
|
|
247
|
+
type PipelineCaptureSource = "browser" | "native";
|
|
248
|
+
type PipelineCaptureKind = "compute" | "render";
|
|
249
|
+
type PipelineCaptureMode = "sync" | "async";
|
|
250
|
+
type PipelineCaptureStatus = "created" | "failed" | "pending";
|
|
251
|
+
interface IPipelineCaptureShader {
|
|
252
|
+
readonly bytes: number;
|
|
253
|
+
readonly hash: string;
|
|
254
|
+
}
|
|
255
|
+
interface IPipelineCaptureProvenance {
|
|
256
|
+
readonly material?: {
|
|
257
|
+
readonly id?: number;
|
|
258
|
+
readonly name?: string;
|
|
259
|
+
readonly type?: string;
|
|
260
|
+
};
|
|
261
|
+
readonly object?: {
|
|
262
|
+
readonly id?: number;
|
|
263
|
+
readonly name?: string;
|
|
264
|
+
readonly uuid?: string;
|
|
265
|
+
};
|
|
266
|
+
readonly unknown: boolean;
|
|
267
|
+
}
|
|
268
|
+
interface IPipelineCaptureEvent {
|
|
269
|
+
readonly sequence: number;
|
|
270
|
+
readonly programIdentity: string;
|
|
271
|
+
readonly pipelineIdentity: string;
|
|
272
|
+
readonly kind: PipelineCaptureKind;
|
|
273
|
+
readonly pass: string;
|
|
274
|
+
readonly mode: PipelineCaptureMode;
|
|
275
|
+
readonly status: PipelineCaptureStatus;
|
|
276
|
+
readonly vertex?: IPipelineCaptureShader;
|
|
277
|
+
readonly fragment?: IPipelineCaptureShader;
|
|
278
|
+
readonly compute?: IPipelineCaptureShader;
|
|
279
|
+
readonly provenance: IPipelineCaptureProvenance;
|
|
280
|
+
readonly reasons: readonly string[];
|
|
281
|
+
readonly startedMs: number;
|
|
282
|
+
readonly settledMs?: number;
|
|
283
|
+
readonly serviceMs?: number;
|
|
284
|
+
readonly promiseMs?: number;
|
|
285
|
+
readonly queueMs?: number;
|
|
286
|
+
readonly wallMs?: number;
|
|
287
|
+
readonly label?: string;
|
|
288
|
+
readonly error?: string;
|
|
289
|
+
readonly nodeBuilds?: number;
|
|
290
|
+
readonly beforeFirstPresent?: boolean;
|
|
291
|
+
readonly beforeWarmUpSettled?: boolean;
|
|
292
|
+
readonly afterWarmUpScope?: string;
|
|
293
|
+
}
|
|
294
|
+
interface IPipelineCaptureNodeBuild {
|
|
295
|
+
readonly provenance: IPipelineCaptureProvenance;
|
|
296
|
+
readonly startedMs: number;
|
|
297
|
+
readonly beforeFirstPresent?: boolean;
|
|
298
|
+
readonly beforeWarmUpSettled?: boolean;
|
|
299
|
+
readonly afterWarmUpScope?: string;
|
|
300
|
+
}
|
|
301
|
+
interface IPipelineCaptureCounts {
|
|
302
|
+
readonly lookups: number;
|
|
303
|
+
readonly creations: number;
|
|
304
|
+
readonly failures: number;
|
|
305
|
+
readonly pending: number;
|
|
306
|
+
readonly uniquePrograms: number;
|
|
307
|
+
readonly uniquePipelines: number;
|
|
308
|
+
readonly recordedEvents: number;
|
|
309
|
+
readonly droppedEvents: number;
|
|
310
|
+
readonly nodeBuilds?: number;
|
|
311
|
+
}
|
|
312
|
+
/**
|
|
313
|
+
* What ended the capture, and therefore what "complete" is allowed to mean.
|
|
314
|
+
*
|
|
315
|
+
* `finalized` is a process that exited: the host drained its compile pool and printed a final
|
|
316
|
+
* count. `checkpoint` is a live snapshot from a present, which is all a run ended by
|
|
317
|
+
* `am force-stop` can produce — every event up to that present is accounted for and nothing was
|
|
318
|
+
* still compiling, and the capture claims nothing about the run after it.
|
|
319
|
+
*/
|
|
320
|
+
interface IPipelineCaptureBoundary {
|
|
321
|
+
readonly kind: "checkpoint" | "finalized";
|
|
322
|
+
readonly events: number;
|
|
323
|
+
readonly outstanding?: number;
|
|
324
|
+
readonly present?: number;
|
|
325
|
+
}
|
|
326
|
+
interface IPipelineCapture {
|
|
327
|
+
readonly version: number;
|
|
328
|
+
readonly source: PipelineCaptureSource;
|
|
329
|
+
readonly boundary?: IPipelineCaptureBoundary;
|
|
330
|
+
readonly complete: boolean;
|
|
331
|
+
readonly overflowed: boolean;
|
|
332
|
+
readonly backend?: Readonly<Record<string, unknown>>;
|
|
333
|
+
readonly clock?: Readonly<Record<string, unknown>>;
|
|
334
|
+
readonly build?: Readonly<Record<string, unknown>>;
|
|
335
|
+
readonly adapter?: Readonly<Record<string, unknown>>;
|
|
336
|
+
readonly firstPresent?: {
|
|
337
|
+
readonly boundaryMs: number;
|
|
338
|
+
readonly eventsSettled: number;
|
|
339
|
+
};
|
|
340
|
+
readonly warmUpSettled?: {
|
|
341
|
+
readonly boundaryMs: number;
|
|
342
|
+
readonly eventsSettled: number;
|
|
343
|
+
readonly nodeBuilds: number;
|
|
344
|
+
readonly renderPipelineCreations: number;
|
|
345
|
+
};
|
|
346
|
+
readonly warmUpScopes?: readonly {
|
|
347
|
+
readonly label: string;
|
|
348
|
+
readonly boundaryMs: number;
|
|
349
|
+
readonly eventsSettled: number;
|
|
350
|
+
readonly nodeBuilds: number;
|
|
351
|
+
readonly renderPipelineCreations: number;
|
|
352
|
+
readonly firstDraw?: {
|
|
353
|
+
readonly nodeBuilds: number;
|
|
354
|
+
readonly renderPipelineCreations: number;
|
|
355
|
+
};
|
|
356
|
+
}[];
|
|
357
|
+
readonly counts: IPipelineCaptureCounts;
|
|
358
|
+
readonly events: readonly IPipelineCaptureEvent[];
|
|
359
|
+
readonly nodeBuilds?: readonly IPipelineCaptureNodeBuild[];
|
|
360
|
+
readonly incompleteReasons: readonly string[];
|
|
361
|
+
}
|
|
362
|
+
interface IPipelinePassSummary {
|
|
363
|
+
readonly creations: number;
|
|
364
|
+
readonly failures: number;
|
|
365
|
+
readonly beforeFirstPresent: number;
|
|
366
|
+
/** Sum of observed device-call service durations; absent when the driver did not expose them. */
|
|
367
|
+
readonly serviceMs?: number;
|
|
368
|
+
readonly serviceSamples: number;
|
|
369
|
+
readonly pass: string;
|
|
370
|
+
}
|
|
371
|
+
interface IPipelineContributorSummary {
|
|
372
|
+
readonly afterWarmUpSettledCreations: number;
|
|
373
|
+
readonly afterWarmUpSettledNodeBuilds: number;
|
|
374
|
+
readonly creations: number;
|
|
375
|
+
readonly failures: number;
|
|
376
|
+
readonly label: string;
|
|
377
|
+
readonly nodeBuilds: number;
|
|
378
|
+
readonly sampleCount: number;
|
|
379
|
+
/** Sum of observed device-call service durations; absent when the driver did not expose them. */
|
|
380
|
+
readonly serviceMs?: number;
|
|
381
|
+
}
|
|
382
|
+
interface IPipelineProgramReasonSummary {
|
|
383
|
+
readonly creations: number;
|
|
384
|
+
readonly programIdentity: string;
|
|
385
|
+
readonly reasons: readonly string[];
|
|
386
|
+
}
|
|
387
|
+
interface IPipelineSizeTimePassSummary {
|
|
388
|
+
readonly meanBytes: number;
|
|
389
|
+
readonly meanServiceMs: number;
|
|
390
|
+
readonly pass: string;
|
|
391
|
+
readonly samples: number;
|
|
392
|
+
}
|
|
393
|
+
interface IPipelineSizeTimeSummary {
|
|
394
|
+
readonly byPass: readonly IPipelineSizeTimePassSummary[];
|
|
395
|
+
readonly samples: number;
|
|
396
|
+
readonly statement: string;
|
|
397
|
+
}
|
|
398
|
+
interface IPipelineWarmupSummary {
|
|
399
|
+
readonly afterFirstPresent: number;
|
|
400
|
+
readonly afterWarmUpSettled: number;
|
|
401
|
+
readonly beforeFirstPresent: number;
|
|
402
|
+
readonly eventsSettledAtFirstPresent?: number;
|
|
403
|
+
readonly eventsSettledAtWarmUpSettled?: number;
|
|
404
|
+
readonly nodeBuildsAfterWarmUpSettled?: number;
|
|
405
|
+
readonly renderPipelineCreationsAfterWarmUpSettled?: number;
|
|
406
|
+
/** Post-boundary work attributed to material contributors already observed during warm-up. */
|
|
407
|
+
readonly warmedNodeBuildsAfterWarmUpSettled?: number;
|
|
408
|
+
readonly warmedRenderPipelineCreationsAfterWarmUpSettled?: number;
|
|
409
|
+
readonly total: number;
|
|
410
|
+
readonly unreported: number;
|
|
411
|
+
readonly scopes: readonly {
|
|
412
|
+
readonly label: string;
|
|
413
|
+
readonly nodeBuilds: number;
|
|
414
|
+
readonly renderPipelineCreations: number;
|
|
415
|
+
readonly observed?: boolean;
|
|
416
|
+
}[];
|
|
417
|
+
}
|
|
418
|
+
interface IPipelineSummary {
|
|
419
|
+
readonly adapter?: Readonly<Record<string, unknown>>;
|
|
420
|
+
readonly boundary?: IPipelineCaptureBoundary;
|
|
421
|
+
readonly build?: Readonly<Record<string, unknown>>;
|
|
422
|
+
readonly complete: boolean;
|
|
423
|
+
readonly counts: IPipelineCaptureCounts;
|
|
424
|
+
readonly contributors: readonly IPipelineContributorSummary[];
|
|
425
|
+
readonly incompleteReasons: readonly string[];
|
|
426
|
+
readonly passTotals: readonly IPipelinePassSummary[];
|
|
427
|
+
readonly programReasons: readonly IPipelineProgramReasonSummary[];
|
|
428
|
+
readonly sizeTime: IPipelineSizeTimeSummary;
|
|
429
|
+
readonly source: PipelineCaptureSource;
|
|
430
|
+
readonly warmup: IPipelineWarmupSummary;
|
|
431
|
+
}
|
|
432
|
+
/** Parse a capture file, either as a JSON browser census or a native log containing markers. */
|
|
433
|
+
declare function parsePipelineCapture(input: string | unknown): IPipelineCapture;
|
|
434
|
+
/** Parse only native marker lines, preserving the same malformed-input contract as perf. */
|
|
435
|
+
declare function parsePipelineEventMarkers(text: string): IPipelineCaptureEvent[];
|
|
436
|
+
declare function summarizePipelineCapture(capture: IPipelineCapture): IPipelineSummary;
|
|
437
|
+
declare function formatPipelineSummary(summary: IPipelineSummary): string;
|
|
438
|
+
|
|
439
|
+
/**
|
|
440
|
+
* The one-minute load average and the core count of the machine that ran the report. Absolute
|
|
441
|
+
* milliseconds measured while more than half the cores are busy are somebody else's contention.
|
|
442
|
+
*
|
|
443
|
+
* This is the rule's one home: `scripts/engine-load-test/report.ts` imports it from here, because a
|
|
444
|
+
* package must not reach into `scripts/` and the benchmark lane must not keep a second copy that can
|
|
445
|
+
* drift from the verdict a playtest gives.
|
|
446
|
+
*/
|
|
447
|
+
interface IPerfHostLoadReading {
|
|
448
|
+
readonly cores: number;
|
|
449
|
+
readonly load1: number;
|
|
450
|
+
}
|
|
451
|
+
interface IPerfHostLoad extends IPerfHostLoadReading {
|
|
452
|
+
readonly absolutes: "invalid-absolute" | "valid";
|
|
453
|
+
}
|
|
454
|
+
interface IPerfHostLoadSource {
|
|
455
|
+
cores(): number;
|
|
456
|
+
loadavg(): number[];
|
|
457
|
+
}
|
|
458
|
+
/** Absolutes are invalid once the one-minute load passes half the cores. */
|
|
459
|
+
declare function absolutesVerdict(reading: IPerfHostLoadReading): IPerfHostLoad["absolutes"];
|
|
460
|
+
/** Defaults to this machine; a spec passes a stub. */
|
|
461
|
+
declare function readHostLoad(source?: IPerfHostLoadSource): IPerfHostLoadReading;
|
|
462
|
+
|
|
244
463
|
declare const ANDROID_TRANSPORT_CAPABILITIES: readonly ["browser.console", "browser.input", "browser.screenshot", "device.metrics", "runtime.diagnostics"];
|
|
245
464
|
interface IDeviceMailbox {
|
|
246
465
|
read(path: string): Promise<string | undefined>;
|
|
@@ -269,7 +488,7 @@ interface IDeviceRequestContext {
|
|
|
269
488
|
}
|
|
270
489
|
interface IDevicePlaytestTransport extends IBridgeTransport {
|
|
271
490
|
start(): Promise<void>;
|
|
272
|
-
setResponseObserver?(observer: (observation: IDeviceResponseObservation) =>
|
|
491
|
+
setResponseObserver?(observer: (observation: IDeviceResponseObservation) => unknown): void;
|
|
273
492
|
getPendingRequest?(): IDeviceRequestContext | undefined;
|
|
274
493
|
}
|
|
275
494
|
declare class DeviceBridgeTransport implements IDevicePlaytestTransport {
|
|
@@ -299,10 +518,11 @@ declare class DeviceMailboxTransport implements IDevicePlaytestTransport {
|
|
|
299
518
|
private nextId;
|
|
300
519
|
private nextOrder;
|
|
301
520
|
private pendingRequest?;
|
|
521
|
+
private responsePoll?;
|
|
302
522
|
private readonly abandonedIds;
|
|
303
523
|
private responseObserver?;
|
|
304
524
|
constructor(mailbox: IDeviceMailbox, paths: IDeviceMailboxPaths, operationTimeoutMs?: number);
|
|
305
|
-
setResponseObserver(observer: (observation: IDeviceResponseObservation) =>
|
|
525
|
+
setResponseObserver(observer: (observation: IDeviceResponseObservation) => unknown): void;
|
|
306
526
|
getPendingRequest(): IDeviceRequestContext | undefined;
|
|
307
527
|
start(): Promise<void>;
|
|
308
528
|
call<T>(method: string, argument?: unknown, timeoutMs?: number): Promise<T>;
|
|
@@ -324,11 +544,14 @@ declare function deviceTimeoutDiagnostic(diagnostic: IPlaytestProtocolDiagnostic
|
|
|
324
544
|
declare function deviceMailboxPaths(root: string): IDeviceMailboxPaths;
|
|
325
545
|
declare function validateDeviceEndpoint(value: string): URL;
|
|
326
546
|
|
|
547
|
+
/** The Android lane: an adb-backed driver handed to the shared device flow in `deviceRunner.ts`. */
|
|
327
548
|
interface IAndroidPlaytestDependencies {
|
|
328
549
|
abortSignal?: AbortSignal;
|
|
329
550
|
driver?: IAndroidDriver;
|
|
330
551
|
transport?: IDevicePlaytestTransport;
|
|
331
552
|
}
|
|
553
|
+
declare function runAndroidPlaytest(config: IStandalonePlaytestConfig, dependencies?: IAndroidPlaytestDependencies): Promise<IStandalonePlaytestReport>;
|
|
554
|
+
|
|
332
555
|
interface IDevicePlaytestDriver {
|
|
333
556
|
readonly processId?: number;
|
|
334
557
|
/** Send the app behind HOME and wait until the device reports it unfocused. */
|
|
@@ -369,7 +592,6 @@ interface IDevicePlaytestTarget {
|
|
|
369
592
|
processName: string;
|
|
370
593
|
transport?: IDevicePlaytestTransport;
|
|
371
594
|
}
|
|
372
|
-
declare function runAndroidPlaytest(config: IStandalonePlaytestConfig, dependencies?: IAndroidPlaytestDependencies): Promise<IStandalonePlaytestReport>;
|
|
373
595
|
declare function runDevicePlaytest(config: IStandalonePlaytestConfig, target: IDevicePlaytestTarget): Promise<IStandalonePlaytestReport>;
|
|
374
596
|
|
|
375
597
|
interface IDesktopPlaytestDriverOptions {
|
|
@@ -501,201 +723,6 @@ declare function runIosPlaytest(config: IStandalonePlaytestConfig, dependencies?
|
|
|
501
723
|
declare function requireAssertions(value: IPlaytestScenario["assert"], scenarioPath: string): NonNullable<IPlaytestScenario["assert"]>;
|
|
502
724
|
declare function recordToScenario(value: unknown, scenarioPath?: string, oracleValue?: unknown): IPlaytestScenario;
|
|
503
725
|
|
|
504
|
-
/** Shared parser and aggregation for browser pipeline censuses and native pipeline markers. */
|
|
505
|
-
declare const PIPELINE_CAPTURE_VERSION: 1;
|
|
506
|
-
declare const PIPELINE_EVENT_MARKER = "TN_PIPELINE_EVENT:";
|
|
507
|
-
type PipelineCaptureSource = "browser" | "native";
|
|
508
|
-
type PipelineCaptureKind = "compute" | "render";
|
|
509
|
-
type PipelineCaptureMode = "sync" | "async";
|
|
510
|
-
type PipelineCaptureStatus = "created" | "failed" | "pending";
|
|
511
|
-
interface IPipelineCaptureShader {
|
|
512
|
-
readonly bytes: number;
|
|
513
|
-
readonly hash: string;
|
|
514
|
-
}
|
|
515
|
-
interface IPipelineCaptureProvenance {
|
|
516
|
-
readonly material?: {
|
|
517
|
-
readonly id?: number;
|
|
518
|
-
readonly name?: string;
|
|
519
|
-
readonly type?: string;
|
|
520
|
-
};
|
|
521
|
-
readonly object?: {
|
|
522
|
-
readonly id?: number;
|
|
523
|
-
readonly name?: string;
|
|
524
|
-
readonly uuid?: string;
|
|
525
|
-
};
|
|
526
|
-
readonly unknown: boolean;
|
|
527
|
-
}
|
|
528
|
-
interface IPipelineCaptureEvent {
|
|
529
|
-
readonly sequence: number;
|
|
530
|
-
readonly programIdentity: string;
|
|
531
|
-
readonly pipelineIdentity: string;
|
|
532
|
-
readonly kind: PipelineCaptureKind;
|
|
533
|
-
readonly pass: string;
|
|
534
|
-
readonly mode: PipelineCaptureMode;
|
|
535
|
-
readonly status: PipelineCaptureStatus;
|
|
536
|
-
readonly vertex?: IPipelineCaptureShader;
|
|
537
|
-
readonly fragment?: IPipelineCaptureShader;
|
|
538
|
-
readonly compute?: IPipelineCaptureShader;
|
|
539
|
-
readonly provenance: IPipelineCaptureProvenance;
|
|
540
|
-
readonly reasons: readonly string[];
|
|
541
|
-
readonly startedMs: number;
|
|
542
|
-
readonly settledMs?: number;
|
|
543
|
-
readonly serviceMs?: number;
|
|
544
|
-
readonly promiseMs?: number;
|
|
545
|
-
readonly queueMs?: number;
|
|
546
|
-
readonly wallMs?: number;
|
|
547
|
-
readonly label?: string;
|
|
548
|
-
readonly error?: string;
|
|
549
|
-
readonly nodeBuilds?: number;
|
|
550
|
-
readonly beforeFirstPresent?: boolean;
|
|
551
|
-
readonly beforeWarmUpSettled?: boolean;
|
|
552
|
-
readonly afterWarmUpScope?: string;
|
|
553
|
-
}
|
|
554
|
-
interface IPipelineCaptureNodeBuild {
|
|
555
|
-
readonly provenance: IPipelineCaptureProvenance;
|
|
556
|
-
readonly startedMs: number;
|
|
557
|
-
readonly beforeFirstPresent?: boolean;
|
|
558
|
-
readonly beforeWarmUpSettled?: boolean;
|
|
559
|
-
readonly afterWarmUpScope?: string;
|
|
560
|
-
}
|
|
561
|
-
interface IPipelineCaptureCounts {
|
|
562
|
-
readonly lookups: number;
|
|
563
|
-
readonly creations: number;
|
|
564
|
-
readonly failures: number;
|
|
565
|
-
readonly pending: number;
|
|
566
|
-
readonly uniquePrograms: number;
|
|
567
|
-
readonly uniquePipelines: number;
|
|
568
|
-
readonly recordedEvents: number;
|
|
569
|
-
readonly droppedEvents: number;
|
|
570
|
-
readonly nodeBuilds?: number;
|
|
571
|
-
}
|
|
572
|
-
/**
|
|
573
|
-
* What ended the capture, and therefore what "complete" is allowed to mean.
|
|
574
|
-
*
|
|
575
|
-
* `finalized` is a process that exited: the host drained its compile pool and printed a final
|
|
576
|
-
* count. `checkpoint` is a live snapshot from a present, which is all a run ended by
|
|
577
|
-
* `am force-stop` can produce — every event up to that present is accounted for and nothing was
|
|
578
|
-
* still compiling, and the capture claims nothing about the run after it.
|
|
579
|
-
*/
|
|
580
|
-
interface IPipelineCaptureBoundary {
|
|
581
|
-
readonly kind: "checkpoint" | "finalized";
|
|
582
|
-
readonly events: number;
|
|
583
|
-
readonly outstanding?: number;
|
|
584
|
-
readonly present?: number;
|
|
585
|
-
}
|
|
586
|
-
interface IPipelineCapture {
|
|
587
|
-
readonly version: number;
|
|
588
|
-
readonly source: PipelineCaptureSource;
|
|
589
|
-
readonly boundary?: IPipelineCaptureBoundary;
|
|
590
|
-
readonly complete: boolean;
|
|
591
|
-
readonly overflowed: boolean;
|
|
592
|
-
readonly backend?: Readonly<Record<string, unknown>>;
|
|
593
|
-
readonly clock?: Readonly<Record<string, unknown>>;
|
|
594
|
-
readonly build?: Readonly<Record<string, unknown>>;
|
|
595
|
-
readonly adapter?: Readonly<Record<string, unknown>>;
|
|
596
|
-
readonly firstPresent?: {
|
|
597
|
-
readonly boundaryMs: number;
|
|
598
|
-
readonly eventsSettled: number;
|
|
599
|
-
};
|
|
600
|
-
readonly warmUpSettled?: {
|
|
601
|
-
readonly boundaryMs: number;
|
|
602
|
-
readonly eventsSettled: number;
|
|
603
|
-
readonly nodeBuilds: number;
|
|
604
|
-
readonly renderPipelineCreations: number;
|
|
605
|
-
};
|
|
606
|
-
readonly warmUpScopes?: readonly {
|
|
607
|
-
readonly label: string;
|
|
608
|
-
readonly boundaryMs: number;
|
|
609
|
-
readonly eventsSettled: number;
|
|
610
|
-
readonly nodeBuilds: number;
|
|
611
|
-
readonly renderPipelineCreations: number;
|
|
612
|
-
readonly firstDraw?: {
|
|
613
|
-
readonly nodeBuilds: number;
|
|
614
|
-
readonly renderPipelineCreations: number;
|
|
615
|
-
};
|
|
616
|
-
}[];
|
|
617
|
-
readonly counts: IPipelineCaptureCounts;
|
|
618
|
-
readonly events: readonly IPipelineCaptureEvent[];
|
|
619
|
-
readonly nodeBuilds?: readonly IPipelineCaptureNodeBuild[];
|
|
620
|
-
readonly incompleteReasons: readonly string[];
|
|
621
|
-
}
|
|
622
|
-
interface IPipelinePassSummary {
|
|
623
|
-
readonly creations: number;
|
|
624
|
-
readonly failures: number;
|
|
625
|
-
readonly beforeFirstPresent: number;
|
|
626
|
-
/** Sum of observed device-call service durations; absent when the driver did not expose them. */
|
|
627
|
-
readonly serviceMs?: number;
|
|
628
|
-
readonly serviceSamples: number;
|
|
629
|
-
readonly pass: string;
|
|
630
|
-
}
|
|
631
|
-
interface IPipelineContributorSummary {
|
|
632
|
-
readonly afterWarmUpSettledCreations: number;
|
|
633
|
-
readonly afterWarmUpSettledNodeBuilds: number;
|
|
634
|
-
readonly creations: number;
|
|
635
|
-
readonly failures: number;
|
|
636
|
-
readonly label: string;
|
|
637
|
-
readonly nodeBuilds: number;
|
|
638
|
-
readonly sampleCount: number;
|
|
639
|
-
/** Sum of observed device-call service durations; absent when the driver did not expose them. */
|
|
640
|
-
readonly serviceMs?: number;
|
|
641
|
-
}
|
|
642
|
-
interface IPipelineProgramReasonSummary {
|
|
643
|
-
readonly creations: number;
|
|
644
|
-
readonly programIdentity: string;
|
|
645
|
-
readonly reasons: readonly string[];
|
|
646
|
-
}
|
|
647
|
-
interface IPipelineSizeTimePassSummary {
|
|
648
|
-
readonly meanBytes: number;
|
|
649
|
-
readonly meanServiceMs: number;
|
|
650
|
-
readonly pass: string;
|
|
651
|
-
readonly samples: number;
|
|
652
|
-
}
|
|
653
|
-
interface IPipelineSizeTimeSummary {
|
|
654
|
-
readonly byPass: readonly IPipelineSizeTimePassSummary[];
|
|
655
|
-
readonly samples: number;
|
|
656
|
-
readonly statement: string;
|
|
657
|
-
}
|
|
658
|
-
interface IPipelineWarmupSummary {
|
|
659
|
-
readonly afterFirstPresent: number;
|
|
660
|
-
readonly afterWarmUpSettled: number;
|
|
661
|
-
readonly beforeFirstPresent: number;
|
|
662
|
-
readonly eventsSettledAtFirstPresent?: number;
|
|
663
|
-
readonly eventsSettledAtWarmUpSettled?: number;
|
|
664
|
-
readonly nodeBuildsAfterWarmUpSettled?: number;
|
|
665
|
-
readonly renderPipelineCreationsAfterWarmUpSettled?: number;
|
|
666
|
-
/** Post-boundary work attributed to material contributors already observed during warm-up. */
|
|
667
|
-
readonly warmedNodeBuildsAfterWarmUpSettled?: number;
|
|
668
|
-
readonly warmedRenderPipelineCreationsAfterWarmUpSettled?: number;
|
|
669
|
-
readonly total: number;
|
|
670
|
-
readonly unreported: number;
|
|
671
|
-
readonly scopes: readonly {
|
|
672
|
-
readonly label: string;
|
|
673
|
-
readonly nodeBuilds: number;
|
|
674
|
-
readonly renderPipelineCreations: number;
|
|
675
|
-
readonly observed?: boolean;
|
|
676
|
-
}[];
|
|
677
|
-
}
|
|
678
|
-
interface IPipelineSummary {
|
|
679
|
-
readonly adapter?: Readonly<Record<string, unknown>>;
|
|
680
|
-
readonly boundary?: IPipelineCaptureBoundary;
|
|
681
|
-
readonly build?: Readonly<Record<string, unknown>>;
|
|
682
|
-
readonly complete: boolean;
|
|
683
|
-
readonly counts: IPipelineCaptureCounts;
|
|
684
|
-
readonly contributors: readonly IPipelineContributorSummary[];
|
|
685
|
-
readonly incompleteReasons: readonly string[];
|
|
686
|
-
readonly passTotals: readonly IPipelinePassSummary[];
|
|
687
|
-
readonly programReasons: readonly IPipelineProgramReasonSummary[];
|
|
688
|
-
readonly sizeTime: IPipelineSizeTimeSummary;
|
|
689
|
-
readonly source: PipelineCaptureSource;
|
|
690
|
-
readonly warmup: IPipelineWarmupSummary;
|
|
691
|
-
}
|
|
692
|
-
/** Parse a capture file, either as a JSON browser census or a native log containing markers. */
|
|
693
|
-
declare function parsePipelineCapture(input: string | unknown): IPipelineCapture;
|
|
694
|
-
/** Parse only native marker lines, preserving the same malformed-input contract as perf. */
|
|
695
|
-
declare function parsePipelineEventMarkers(text: string): IPipelineCaptureEvent[];
|
|
696
|
-
declare function summarizePipelineCapture(capture: IPipelineCapture): IPipelineSummary;
|
|
697
|
-
declare function formatPipelineSummary(summary: IPipelineSummary): string;
|
|
698
|
-
|
|
699
726
|
interface IBrowserCaptureSession {
|
|
700
727
|
readonly bridge: IPlaytestBridgeClient;
|
|
701
728
|
/** Console errors collected from page creation through the custom capture callback. */
|
|
@@ -719,4 +746,4 @@ interface IBrowserCaptureSession {
|
|
|
719
746
|
*/
|
|
720
747
|
declare function withBrowserCapture<T>(config: IStandalonePlaytestConfig, capture: (session: IBrowserCaptureSession) => Promise<T>, signal?: AbortSignal): Promise<T>;
|
|
721
748
|
|
|
722
|
-
export { ANDROID_TRANSPORT_CAPABILITIES, DesktopPlaytestDriver, DeviceBridgeTransport, DeviceMailboxTransport, IAndroidAppState, IAndroidDriver, type IAndroidPlaytestDependencies, IAndroidPointer, IAndroidPointerInjection, type IBridgeTransport, type IBrowserCaptureSession, type IBrowserPointerChange, type IDesktopPlaytestDependencies, type IDesktopPlaytestDriverOptions, type IDeviceMailbox, type IDeviceMailboxPaths, type IDevicePlaytestDriver, type IDevicePlaytestTarget, type IDevicePlaytestTransport, type IDeviceRequestContext, type IDeviceResponseObservation, type IDisplayStrategy, type IIosCommandOptions, type IIosDriverOptions, type IIosPlaytestDependencies, ILabeledPlaytestSample, IMovementSampleInterval, type IPipelineCapture, type IPipelineCaptureBoundary, type IPipelineCaptureCounts, type IPipelineCaptureEvent, type IPipelineCaptureNodeBuild, type IPipelineCaptureProvenance, type IPipelineCaptureShader, type IPipelineContributorSummary, type IPipelinePassSummary, type IPipelineProgramReasonSummary, type IPipelineSizeTimePassSummary, type IPipelineSizeTimeSummary, type IPipelineSummary, type IPipelineWarmupSummary, type IPlaytestBridgeClient, type IRunIosCommand, IRunnerConsoleEntry, IStandalonePlaytestConfig, IStandalonePlaytestReport, type IStandalonePlaytestRunOptions, type IosTransportKind, LocalDeviceMailbox, PENDING_BRIDGE_OPERATIONS_GLOBAL, PERFORMANCE_BROWSER_ARGS, PIPELINE_CAPTURE_VERSION, PIPELINE_EVENT_MARKER, type PipelineCaptureKind, type PipelineCaptureMode, type PipelineCaptureSource, type PipelineCaptureStatus, PlaytestBridgeError, PlaywrightTransport, STANDALONE_PLAYTEST_OBSERVATION_FIELDS, WEBGPU_BROWSER_ARGS, XcrunIosDriver, advanceTimeoutMs, androidMailboxPaths, batchArtifactDirectory, boundedTeardownStep, bridgeWaitTimeoutMs, buildReport, connectPlaytestBridge, connectPlaytestBridgeTransport, decideDisplayStrategy, desktopConsoleType, deviceMailboxPaths, deviceTimeoutDiagnostic, formatPipelineSummary, handlePlaytestSignal, initStandalonePlaytest, isRuntimeReadout, openPageAndConnectBridge, pageLifecycleDiagnostic, parseLaunchedPid, parsePipelineCapture, parsePipelineEventMarkers, preflightDisplay, reconcileBrowserPointers, recordToScenario, requireAssertions, resolveBrowserArguments, resolveManagedServerCommand, resolveManagedServerConfig, runAndroidPlaytest, runDesktopPlaytest, runDevicePlaytest, runIosPlaytest, runStandalonePlaytest, runStandalonePlaytests, softwareAdapterName, substituteManagedPort, summarizePipelineCapture, validateDeviceEndpoint, withBrowserCapture, writeCaptureProvenance, writeObservationArtifacts };
|
|
749
|
+
export { ANDROID_TRANSPORT_CAPABILITIES, DesktopPlaytestDriver, DeviceBridgeTransport, DeviceMailboxTransport, IAndroidAppState, IAndroidDriver, type IAndroidPlaytestDependencies, IAndroidPointer, IAndroidPointerInjection, type IBridgeTransport, type IBrowserCaptureSession, type IBrowserPointerChange, type IDesktopPlaytestDependencies, type IDesktopPlaytestDriverOptions, type IDeviceMailbox, type IDeviceMailboxPaths, type IDevicePlaytestDriver, type IDevicePlaytestTarget, type IDevicePlaytestTransport, type IDeviceRequestContext, type IDeviceResponseObservation, type IDisplayStrategy, type IIosCommandOptions, type IIosDriverOptions, type IIosPlaytestDependencies, ILabeledPlaytestSample, IMovementSampleInterval, type IPerfHostLoad, type IPerfHostLoadReading, type IPerfHostLoadSource, type IPipelineCapture, type IPipelineCaptureBoundary, type IPipelineCaptureCounts, type IPipelineCaptureEvent, type IPipelineCaptureNodeBuild, type IPipelineCaptureProvenance, type IPipelineCaptureShader, type IPipelineContributorSummary, type IPipelinePassSummary, type IPipelineProgramReasonSummary, type IPipelineSizeTimePassSummary, type IPipelineSizeTimeSummary, type IPipelineSummary, type IPipelineWarmupSummary, type IPlaytestBridgeClient, type IRunIosCommand, IRunnerConsoleEntry, IStandalonePlaytestConfig, IStandalonePlaytestReport, type IStandalonePlaytestRunOptions, type IosTransportKind, LocalDeviceMailbox, PENDING_BRIDGE_OPERATIONS_GLOBAL, PERFORMANCE_BROWSER_ARGS, PIPELINE_CAPTURE_VERSION, PIPELINE_EVENT_MARKER, type PipelineCaptureKind, type PipelineCaptureMode, type PipelineCaptureSource, type PipelineCaptureStatus, PlaytestBridgeError, PlaywrightTransport, STANDALONE_PLAYTEST_OBSERVATION_FIELDS, WEBGPU_BROWSER_ARGS, XcrunIosDriver, absolutesVerdict, advanceTimeoutMs, androidMailboxPaths, batchArtifactDirectory, boundedTeardownStep, bridgeWaitTimeoutMs, buildReport, connectPlaytestBridge, connectPlaytestBridgeTransport, decideDisplayStrategy, desktopConsoleType, deviceMailboxPaths, deviceTimeoutDiagnostic, formatPipelineSummary, handlePlaytestSignal, initStandalonePlaytest, isRuntimeReadout, openPageAndConnectBridge, pageLifecycleDiagnostic, parseLaunchedPid, parsePipelineCapture, parsePipelineEventMarkers, preflightDisplay, readHostLoad, reconcileBrowserPointers, recordToScenario, requireAssertions, resolveBrowserArguments, resolveManagedServerCommand, resolveManagedServerConfig, runAndroidPlaytest, runDesktopPlaytest, runDevicePlaytest, runIosPlaytest, runStandalonePlaytest, runStandalonePlaytests, softwareAdapterName, substituteManagedPort, summarizePipelineCapture, validateDeviceEndpoint, withBrowserCapture, writeCaptureProvenance, writeObservationArtifacts };
|