@devicecloud.dev/dcd 4.2.6 → 4.3.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.
@@ -57,6 +57,7 @@ export default class Cloud extends Command {
57
57
  'show-crosshairs': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
58
58
  'maestro-chrome-onboarding': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
59
59
  'android-no-snapshot': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
60
+ 'enable-animations': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
60
61
  'app-binary-id': import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
61
62
  'app-file': import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
62
63
  'ignore-sha-check': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
@@ -404,6 +404,7 @@ class Cloud extends core_1.Command {
404
404
  runnerType,
405
405
  showCrosshairs: flags['show-crosshairs'],
406
406
  maestroChromeOnboarding: flags['maestro-chrome-onboarding'],
407
+ enableAnimations: flags['enable-animations'],
407
408
  });
408
409
  if (debug) {
409
410
  this.log(`[DEBUG] Submitting flow upload request to ${apiUrl}/uploads/flow`);
@@ -490,7 +491,7 @@ class Cloud extends core_1.Command {
490
491
  warnLogger: this.warn.bind(this),
491
492
  });
492
493
  }
493
- if (report && ['allure', 'html', 'junit'].includes(report)) {
494
+ if (report && ['allure', 'html', 'html-detailed', 'junit'].includes(report)) {
494
495
  await this.reportDownloadService.downloadReports({
495
496
  allurePath,
496
497
  apiKey,
@@ -522,7 +523,7 @@ class Cloud extends core_1.Command {
522
523
  });
523
524
  }
524
525
  // Handle report downloads based on --report flag
525
- if (report && ['allure', 'html', 'junit'].includes(report)) {
526
+ if (report && ['allure', 'html', 'html-detailed', 'junit'].includes(report)) {
526
527
  await this.reportDownloadService.downloadReports({
527
528
  allurePath,
528
529
  apiKey,
@@ -12,4 +12,5 @@ export declare const deviceFlags: {
12
12
  'show-crosshairs': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
13
13
  'maestro-chrome-onboarding': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
14
14
  'android-no-snapshot': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
15
+ 'enable-animations': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
15
16
  };
@@ -47,4 +47,8 @@ exports.deviceFlags = {
47
47
  default: false,
48
48
  description: '[Android only] Force cold boot instead of using snapshot boot. This is automatically enabled for API 35+ but can be used to force cold boot on older API levels.',
49
49
  }),
50
+ 'enable-animations': core_1.Flags.boolean({
51
+ default: false,
52
+ description: '[Android only] Keep device animations enabled during test execution. By default, animations are disabled to reduce CPU load and improve test reliability.',
53
+ }),
50
54
  };
@@ -37,7 +37,7 @@ exports.executionFlags = {
37
37
  }),
38
38
  'maestro-version': core_1.Flags.string({
39
39
  aliases: ['maestroVersion'],
40
- description: 'Maestro version to run your flow against. Use "latest" for the most recent version. Supported versions are fetched from the API.',
40
+ description: 'Maestro version to run your flow against. Use "latest" for the most recent version. See https://docs.devicecloud.dev/reference/maestro-versions for supported versions.',
41
41
  }),
42
42
  retry: core_1.Flags.integer({
43
43
  description: 'Automatically retry the run up to the number of times specified (same as pressing retry in the UI) - this is free of charge',
@@ -56,6 +56,6 @@ exports.outputFlags = {
56
56
  report: core_1.Flags.string({
57
57
  aliases: ['format'],
58
58
  description: 'Generate and download test reports in the specified format. Use "allure" for a complete HTML report.',
59
- options: ['allure', 'junit', 'html'],
59
+ options: ['allure', 'junit', 'html', 'html-detailed'],
60
60
  }),
61
61
  };
@@ -44,6 +44,7 @@ export declare const flags: {
44
44
  'show-crosshairs': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
45
45
  'maestro-chrome-onboarding': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
46
46
  'android-no-snapshot': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
47
+ 'enable-animations': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
47
48
  'app-binary-id': import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
48
49
  'app-file': import("@oclif/core/lib/interfaces").OptionFlag<string, import("@oclif/core/lib/interfaces").CustomOptions>;
49
50
  'ignore-sha-check': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
@@ -23,6 +23,7 @@ export declare const ApiGateway: {
23
23
  apiKey: string;
24
24
  backblazeSuccess: boolean;
25
25
  baseUrl: string;
26
+ bytes: number;
26
27
  id: string;
27
28
  metadata: TAppMetadata;
28
29
  path: string;
@@ -35,6 +36,7 @@ export declare const ApiGateway: {
35
36
  finalPath: string;
36
37
  id: string;
37
38
  b2?: import("../types/generated/schema.types").components["schemas"]["B2UploadStrategy"];
39
+ token?: string;
38
40
  }>;
39
41
  finishLargeFile(baseUrl: string, apiKey: string, fileId: string, partSha1Array: string[]): Promise<any>;
40
42
  getResultsForUpload(baseUrl: string, apiKey: string, uploadId: string): Promise<{
@@ -156,11 +156,12 @@ exports.ApiGateway = {
156
156
  }
157
157
  },
158
158
  async finaliseUpload(config) {
159
- const { baseUrl, apiKey, id, metadata, path, sha, supabaseSuccess, backblazeSuccess } = config;
159
+ const { baseUrl, apiKey, id, metadata, path, sha, supabaseSuccess, backblazeSuccess, bytes } = config;
160
160
  try {
161
161
  const res = await fetch(`${baseUrl}/uploads/finaliseUpload`, {
162
162
  body: JSON.stringify({
163
163
  backblazeSuccess,
164
+ bytes,
164
165
  id,
165
166
  metadata,
166
167
  path, // This is tempPath for TUS uploads
package/dist/methods.js CHANGED
@@ -523,6 +523,7 @@ async function performUpload(config) {
523
523
  apiKey,
524
524
  backblazeSuccess: backblazeResult.success,
525
525
  baseUrl: apiUrl,
526
+ bytes: file.size,
526
527
  id,
527
528
  metadata,
528
529
  path: tempPath,
@@ -14,7 +14,7 @@ export interface ReportDownloadOptions extends DownloadOptions {
14
14
  allurePath?: string;
15
15
  htmlPath?: string;
16
16
  junitPath?: string;
17
- reportType: 'allure' | 'html' | 'junit';
17
+ reportType: 'allure' | 'html' | 'html-detailed' | 'junit';
18
18
  }
19
19
  /**
20
20
  * Service for downloading test artifacts and reports
@@ -57,7 +57,8 @@ class ReportDownloadService {
57
57
  });
58
58
  break;
59
59
  }
60
- case 'html': {
60
+ case 'html':
61
+ case 'html-detailed': {
61
62
  const htmlReportPath = path.resolve(process.cwd(), htmlPath || 'report.html');
62
63
  await this.downloadReport('html', htmlReportPath, {
63
64
  ...downloadOptions,
@@ -9,6 +9,7 @@ export interface TestSubmissionConfig {
9
9
  continueOnFailure?: boolean;
10
10
  debug?: boolean;
11
11
  deviceLocale?: string;
12
+ enableAnimations?: boolean;
12
13
  env?: string[];
13
14
  executionPlan: IExecutionPlan;
14
15
  flowFile: string;
@@ -17,7 +17,7 @@ class TestSubmissionService {
17
17
  * @returns FormData ready to be submitted to the API
18
18
  */
19
19
  async buildTestFormData(config) {
20
- const { appBinaryId, flowFile, executionPlan, commonRoot, cliVersion, env = [], metadata = [], googlePlay = false, androidApiLevel, androidDevice, androidNoSnapshot, iOSVersion, iOSDevice, name, runnerType, maestroVersion, deviceLocale, orientation, mitmHost, mitmPath, retry, continueOnFailure = true, report, showCrosshairs, maestroChromeOnboarding, raw, debug = false, logger, } = config;
20
+ const { appBinaryId, flowFile, executionPlan, commonRoot, cliVersion, env = [], metadata = [], googlePlay = false, androidApiLevel, androidDevice, androidNoSnapshot, iOSVersion, iOSDevice, name, runnerType, maestroVersion, deviceLocale, orientation, mitmHost, mitmPath, retry, continueOnFailure = true, report, showCrosshairs, maestroChromeOnboarding, raw, enableAnimations, debug = false, logger, } = config;
21
21
  const { allExcludeTags, allIncludeTags, flowMetadata, flowOverrides, flowsToRun: testFileNames, referencedFiles, sequence, workspaceConfig, } = executionPlan;
22
22
  const { flows: sequentialFlows = [] } = sequence ?? {};
23
23
  const testFormData = new FormData();
@@ -65,7 +65,8 @@ class TestSubmissionService {
65
65
  testFormData.set('testFileOverrides', JSON.stringify(this.normalizePathMap(flowOverrides, commonRoot)));
66
66
  testFormData.set('sequentialFlows', JSON.stringify(this.normalizePaths(sequentialFlows, commonRoot)));
67
67
  testFormData.set('env', JSON.stringify(envObject));
68
- testFormData.set('googlePlay', googlePlay ? 'true' : 'false');
68
+ // Note: googlePlay is now included in configPayload below instead of as a separate field
69
+ // to work around a FormData parsing issue in the API
69
70
  const configPayload = {
70
71
  allExcludeTags,
71
72
  allIncludeTags,
@@ -73,6 +74,7 @@ class TestSubmissionService {
73
74
  autoRetriesRemaining: retry,
74
75
  continueOnFailure,
75
76
  deviceLocale,
77
+ googlePlay,
76
78
  maestroVersion,
77
79
  mitmHost,
78
80
  mitmPath,
@@ -81,6 +83,7 @@ class TestSubmissionService {
81
83
  report,
82
84
  showCrosshairs,
83
85
  maestroChromeOnboarding,
86
+ enableAnimations,
84
87
  version: cliVersion,
85
88
  };
86
89
  testFormData.set('config', JSON.stringify(configPayload));