Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/cli-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ jobs:
path: cli

- name: Setup pnpm
uses: pnpm/action-setup@v6.0.10
uses: pnpm/action-setup@v6.1.0
with:
version: 10
run_install: false
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
- uses: actions/checkout@v7
# Setup .npmrc file to publish to npm
- name: Setup pnpm
uses: pnpm/action-setup@v6.0.10
uses: pnpm/action-setup@v6.1.0
with:
run_install: false

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-binaries.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
- uses: actions/checkout@v7

- name: Setup pnpm
uses: pnpm/action-setup@v6.0.10
uses: pnpm/action-setup@v6.1.0
with:
run_install: false

Expand Down
2 changes: 1 addition & 1 deletion .mocharc.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"node-option": ["import=tsx"],
"node-option": ["import=tsx/esm"],
"extensions": ["ts"],
"watch-extensions": ["ts"],
"recursive": true,
Expand Down
453 changes: 282 additions & 171 deletions pnpm-lock.yaml

Large diffs are not rendered by default.

9 changes: 8 additions & 1 deletion scripts/test-runner.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -162,9 +162,16 @@ async function runTests() {
}

// Run tests. Mocha + .mocharc.json handle TypeScript loading via `tsx`
// (see `node-option: ["import=tsx"]` there). Mocha 11 imports files as
// (see `node-option: ["import=tsx/esm"]` there). Mocha imports files as
// ESM, so the `require: ts-node/register` hook doesn't get applied; tsx
// registers an ESM loader that resolves TS relative imports correctly.
// It has to be `tsx/esm` rather than bare `tsx`: the latter also patches
// the CJS resolver, which rewrites an ESM dependency's `import` into a
// `require` and then cannot resolve an import-only `exports` map. Mocha's
// own lib/cli/*.cjs requires ESM-only find-up@8, whose unicorn-magic
// dependency exports nothing under the `require` condition — plain Node
// loads that fine via require(esm); tsx's CJS hook throws
// ERR_PACKAGE_PATH_NOT_EXPORTED before a single test runs.
console.log('Running tests...');
const mochaArgs = [
'mocha',
Expand Down
7 changes: 7 additions & 0 deletions src/commands/cloud.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ const DOWNLOAD_OPTIONS = ['ALL', 'FAILED'] as const;
const REPORT_OPTIONS = ['allure', 'html', 'html-detailed', 'junit'] as const;
const ORIENTATION_OPTIONS = ['0', '90'] as const;
const RUNNER_TYPE_OPTIONS = ['default', 'm4', 'm1', 'gpu1', 'cpu1'] as const;
const RENDER_ENGINE_OPTIONS = ['lavapipe', 'swiftshader'] as const;

/**
* Primary CLI command for executing tests on DeviceCloud.
Expand Down Expand Up @@ -257,6 +258,11 @@ export const cloudCommand = defineCommand({
RUNNER_TYPE_OPTIONS,
'runner-type',
) ?? 'default';
const renderEngine = validateEnum(
args['render-engine'] as string | undefined,
RENDER_ENGINE_OPTIONS,
'render-engine',
);
const showCrosshairs = Boolean(args['show-crosshairs']);
const maestroChromeOnboarding = Boolean(args['maestro-chrome-onboarding']);
const disableAnimations = Boolean(args['disable-animations']);
Expand Down Expand Up @@ -838,6 +844,7 @@ export const cloudCommand = defineCommand({
showCrosshairs,
maestroChromeOnboarding,
disableAnimations,
renderEngine,
});

// Device-matrix cost preview: the server prices the exact fan-out (quote
Expand Down
2 changes: 1 addition & 1 deletion src/commands/live.ts
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ const startSub = defineCommand({
'android-device': {
type: 'string',
description:
'[Android] Device profile to match a cloud run (options: pixel-6, pixel-6-pro, pixel-7, pixel-7-pro)',
'[Android] Device profile to match a cloud run (options: pixel-6, pixel-6-pro, pixel-7, pixel-7-pro, pixel-8, pixel-10, pixel-10-pro, pixel-10-pro-xl, pixel-10-pro-fold, pixel-11)',
},
'android-api-level': {
type: 'string',
Expand Down
5 changes: 5 additions & 0 deletions src/config/flags/device.flags.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,11 @@ export const deviceFlags = {
type: 'string',
description: `[Android only] Android device to run your flow against (options: ${androidDevices})`,
},
'render-engine': {
type: 'string',
description:
'[Android only] Software renderer the emulator boots with (options: lavapipe, swiftshader). Defaults to lavapipe; pick swiftshader if your app fails to render or the device drops out mid-run. Apps shipping the Flutter engine are detected and switched automatically, so this is only needed to override that.',
},
'device-locale': {
type: 'string',
description:
Expand Down
8 changes: 8 additions & 0 deletions src/services/test-submission.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,12 @@ export interface TestSubmissionConfig {
name?: string;
orientation?: string;
raw?: unknown;
/**
* Which emulator software renderer to boot with (Android only). Omitted
* means the server decides: lavapipe by default, or swiftshader when the
* binary is detected as shipping the Flutter engine.
*/
renderEngine?: 'lavapipe' | 'swiftshader';
report?: string;
retry?: number;
runnerType?: string;
Expand Down Expand Up @@ -93,6 +99,7 @@ export class TestSubmissionService {
orientation,
retry,
continueOnFailure = true,
renderEngine,
report,
showCrosshairs,
maestroChromeOnboarding,
Expand Down Expand Up @@ -281,6 +288,7 @@ export class TestSubmissionService {
maestroVersion,
orientation,
raw: JSON.stringify(raw),
renderEngine,
report,
showCrosshairs,
maestroChromeOnboarding,
Expand Down
6 changes: 6 additions & 0 deletions src/types/domain/device.types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,12 @@ export enum EAndroidDevices {
'pixel-6-pro' = 'pixel-6-pro',
'pixel-7' = 'pixel-7',
'pixel-7-pro' = 'pixel-7-pro',
'pixel-8' = 'pixel-8',
'pixel-10' = 'pixel-10',
'pixel-10-pro' = 'pixel-10-pro',
'pixel-10-pro-xl' = 'pixel-10-pro-xl',
'pixel-10-pro-fold' = 'pixel-10-pro-fold',
'pixel-11' = 'pixel-11',
}

export enum EiOSVersions {
Expand Down
83 changes: 69 additions & 14 deletions src/types/generated/schema.types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -424,7 +424,7 @@ export interface paths {
patch?: never;
trace?: never;
};
"/org/update-gpu-retries": {
"/org/update-retry-escalation": {
parameters: {
query?: never;
header?: never;
Expand All @@ -433,7 +433,7 @@ export interface paths {
};
get?: never;
put?: never;
post: operations["OrgController_updateGpuRetries"];
post: operations["OrgController_updateRetryEscalation"];
delete?: never;
options?: never;
head?: never;
Expand Down Expand Up @@ -1643,7 +1643,7 @@ export interface components {
/** @enum {string} */
androidApiLevel?: "29" | "30" | "31" | "32" | "33" | "34" | "35" | "36" | "37";
/** @enum {string} */
androidDevice?: "pixel-6" | "pixel-6-pro" | "pixel-7" | "pixel-7-pro" | "generic-tablet";
androidDevice?: "pixel-6" | "pixel-6-pro" | "pixel-7" | "pixel-7-pro" | "pixel-8" | "pixel-10" | "pixel-10-pro" | "pixel-10-pro-xl" | "pixel-10-pro-fold" | "pixel-11" | "generic-tablet";
apiKey?: string;
apiUrl?: string;
appBinaryId: string;
Expand Down Expand Up @@ -1683,7 +1683,7 @@ export interface components {
/** @enum {string} */
androidApiLevel?: "29" | "30" | "31" | "32" | "33" | "34" | "35" | "36" | "37";
/** @enum {string} */
androidDevice?: "pixel-6" | "pixel-6-pro" | "pixel-7" | "pixel-7-pro" | "generic-tablet";
androidDevice?: "pixel-6" | "pixel-6-pro" | "pixel-7" | "pixel-7-pro" | "pixel-8" | "pixel-10" | "pixel-10-pro" | "pixel-10-pro-xl" | "pixel-10-pro-fold" | "pixel-11" | "generic-tablet";
apiKey?: string;
apiUrl?: string;
appBinaryId: string;
Expand Down Expand Up @@ -1734,7 +1734,7 @@ export interface components {
/** @enum {string} */
androidApiLevel?: "29" | "30" | "31" | "32" | "33" | "34" | "35" | "36" | "37";
/** @enum {string} */
androidDevice?: "pixel-6" | "pixel-6-pro" | "pixel-7" | "pixel-7-pro" | "generic-tablet";
androidDevice?: "pixel-6" | "pixel-6-pro" | "pixel-7" | "pixel-7-pro" | "pixel-8" | "pixel-10" | "pixel-10-pro" | "pixel-10-pro-xl" | "pixel-10-pro-fold" | "pixel-11" | "generic-tablet";
apiKey?: string;
apiUrl?: string;
appBinaryId: string;
Expand Down Expand Up @@ -2632,7 +2632,7 @@ export interface operations {
};
};
};
OrgController_updateGpuRetries: {
OrgController_updateRetryEscalation: {
parameters: {
query?: never;
header?: never;
Expand All @@ -2643,12 +2643,12 @@ export interface operations {
content: {
"application/json": {
orgId: number;
gpuRetries: boolean;
enabled: boolean;
};
};
};
responses: {
/** @description GPU retries setting updated successfully. */
/** @description Retry escalation setting updated successfully. */
201: {
headers: {
[name: string]: unknown;
Expand Down Expand Up @@ -3018,7 +3018,8 @@ export interface operations {
* "33",
* "34",
* "35",
* "36"
* "36",
* "37"
* ],
* "deprecated": false
* },
Expand All @@ -3036,7 +3037,8 @@ export interface operations {
* "33",
* "34",
* "35",
* "36"
* "36",
* "37"
* ],
* "deprecated": false
* },
Expand All @@ -3046,14 +3048,66 @@ export interface operations {
* "33",
* "34",
* "35",
* "36"
* "36",
* "37"
* ],
* "deprecated": false
* },
* "pixel-8": {
* "name": "Pixel 8",
* "apiLevels": [
* "34",
* "35",
* "36",
* "37"
* ],
* "deprecated": false
* },
* "pixel-10": {
* "name": "Pixel 10",
* "apiLevels": [
* "36",
* "37"
* ],
* "deprecated": false
* },
* "pixel-10-pro": {
* "name": "Pixel 10 Pro",
* "apiLevels": [
* "36",
* "37"
* ],
* "deprecated": false
* },
* "pixel-10-pro-xl": {
* "name": "Pixel 10 Pro XL",
* "apiLevels": [
* "36",
* "37"
* ],
* "deprecated": false
* },
* "pixel-10-pro-fold": {
* "name": "Pixel 10 Pro Fold",
* "apiLevels": [
* "36",
* "37"
* ],
* "deprecated": false
* },
* "pixel-11": {
* "name": "Pixel 11",
* "apiLevels": [
* "37"
* ],
* "deprecated": false
* },
* "generic-tablet": {
* "name": "Generic Tablet",
* "apiLevels": [
* "33"
* "33",
* "36",
* "37"
* ],
* "deprecated": false
* }
Expand All @@ -3079,10 +3133,11 @@ export interface operations {
* "2.6.1",
* "2.7.0",
* "2.8.0",
* "2.9.0"
* "2.9.0",
* "2.10.0"
* ],
* "defaultVersion": "2.2.0",
* "latestVersion": "2.9.0"
* "latestVersion": "2.10.0"
* }
* }
* }
Expand Down
Loading