@devicecloud.dev/dcd 3.6.3 → 3.6.5
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/commands/cloud.js +6 -37
- package/oclif.manifest.json +1 -1
- package/package.json +3 -3
package/dist/commands/cloud.js
CHANGED
|
@@ -85,26 +85,6 @@ class Cloud extends core_1.Command {
|
|
|
85
85
|
let output = null;
|
|
86
86
|
try {
|
|
87
87
|
const { args, flags, raw } = await this.parse(Cloud);
|
|
88
|
-
// Log the full command that was run
|
|
89
|
-
const commandParts = ['dcd cloud'];
|
|
90
|
-
if (args.firstFile)
|
|
91
|
-
commandParts.push(escapeShellValue(args.firstFile));
|
|
92
|
-
if (args.secondFile)
|
|
93
|
-
commandParts.push(escapeShellValue(args.secondFile));
|
|
94
|
-
for (const [key, value] of Object.entries(flags)) {
|
|
95
|
-
if (value && value.toString().length > 0) {
|
|
96
|
-
if (typeof value === 'boolean') {
|
|
97
|
-
commandParts.push(`--${key}`);
|
|
98
|
-
}
|
|
99
|
-
else if (Array.isArray(value)) {
|
|
100
|
-
commandParts.push(`--${key}=${value.map((v) => escapeShellValue(v)).join(',')}`);
|
|
101
|
-
}
|
|
102
|
-
else {
|
|
103
|
-
commandParts.push(`--${key}=${escapeShellValue(value.toString())}`);
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
}
|
|
107
|
-
this.log(`\nCommand ran: ${commandParts.join(' ')}\n`);
|
|
108
88
|
let { 'additional-app-binary-ids': nonFlatAdditionalAppBinaryIds, 'additional-app-files': nonFlatAdditionalAppFiles, 'android-api-level': androidApiLevel, 'android-device': androidDevice, apiKey: apiKeyFlag, apiUrl, 'app-binary-id': appBinaryId, 'app-file': appFile, 'artifacts-path': artifactsPath, async, config: configFile, 'device-locale': deviceLocale, 'download-artifacts': downloadArtifacts, env, 'exclude-flows': excludeFlows, 'exclude-tags': excludeTags, flows, 'google-play': googlePlay, 'include-tags': includeTags, 'ignore-sha-check': ignoreShaCheck, 'ios-device': iOSDevice, 'ios-version': iOSVersion, 'maestro-version': maestroVersion, name, orientation, quiet, retry, report, 'runner-type': runnerType, 'x86-arch': x86Arch, json, ...rest } = flags;
|
|
109
89
|
if (json) {
|
|
110
90
|
const originalStdoutWrite = process.stdout.write;
|
|
@@ -136,24 +116,10 @@ class Cloud extends core_1.Command {
|
|
|
136
116
|
retry = 2;
|
|
137
117
|
}
|
|
138
118
|
if (runnerType === 'm4') {
|
|
139
|
-
this.log('Note: runnerType m4 is experimental and currently supports iOS only.');
|
|
140
|
-
// todo - better platform checking
|
|
141
|
-
if (androidApiLevel || androidDevice) {
|
|
142
|
-
throw new Error('runnerType m4 only supports iOS');
|
|
143
|
-
}
|
|
119
|
+
this.log('Note: runnerType m4 is experimental and currently supports iOS only, Android will revert to default.');
|
|
144
120
|
}
|
|
145
121
|
if (runnerType === 'm1') {
|
|
146
|
-
this.log('Note:
|
|
147
|
-
// todo - better platform checking
|
|
148
|
-
if (iOSDevice || iOSVersion) {
|
|
149
|
-
this.log('runnerType m1 only supports Android, reverting to default');
|
|
150
|
-
runnerType = 'default';
|
|
151
|
-
}
|
|
152
|
-
if (androidApiLevel || androidDevice) {
|
|
153
|
-
this.log('Runner Type m1 only supports API Level 34 and Pixel 7, unsetting your android options.');
|
|
154
|
-
androidApiLevel = undefined;
|
|
155
|
-
androidDevice = undefined;
|
|
156
|
-
}
|
|
122
|
+
this.log('Note: runnerType m1 is experimental and currently supports Android (Pixel 7, API Level 34) only.');
|
|
157
123
|
}
|
|
158
124
|
const additionalAppBinaryIds = nonFlatAdditionalAppBinaryIds?.flat();
|
|
159
125
|
const additionalAppFiles = nonFlatAdditionalAppFiles?.flat();
|
|
@@ -340,6 +306,7 @@ class Cloud extends core_1.Command {
|
|
|
340
306
|
const { message, results } = await (0, methods_1.typeSafePost)(apiUrl, '/uploads/flow', options);
|
|
341
307
|
if (!results?.length)
|
|
342
308
|
(0, errors_1.error)('No tests created: ' + message);
|
|
309
|
+
this.log(message);
|
|
343
310
|
this.log(`\nCreated ${results.length} tests: ${results
|
|
344
311
|
.map((r) => r.test_file_name)
|
|
345
312
|
.sort((a, b) => a.localeCompare(b))
|
|
@@ -497,7 +464,9 @@ class Cloud extends core_1.Command {
|
|
|
497
464
|
if (error instanceof Error && error.message === 'RUN_FAILED') {
|
|
498
465
|
this.exit(2);
|
|
499
466
|
}
|
|
500
|
-
|
|
467
|
+
else {
|
|
468
|
+
this.error(error, { exit: 1 });
|
|
469
|
+
}
|
|
501
470
|
}
|
|
502
471
|
finally {
|
|
503
472
|
if (output) {
|
package/oclif.manifest.json
CHANGED
package/package.json
CHANGED
|
@@ -71,7 +71,7 @@
|
|
|
71
71
|
"scripts": {
|
|
72
72
|
"dcd": "./bin/dev.js",
|
|
73
73
|
"prod": "./bin/run.js",
|
|
74
|
-
"build": "shx rm -rf dist && tsc -b",
|
|
74
|
+
"build": "shx rm -rf dist && tsc -b",
|
|
75
75
|
"lint": "eslint . --ext .ts",
|
|
76
76
|
"postpack": "shx rm -f oclif.manifest.json",
|
|
77
77
|
"posttest": "yarn lint",
|
|
@@ -79,7 +79,7 @@
|
|
|
79
79
|
"prepare": "yarn build",
|
|
80
80
|
"version": "oclif readme && git add README.md"
|
|
81
81
|
},
|
|
82
|
-
"version": "3.6.
|
|
82
|
+
"version": "3.6.5",
|
|
83
83
|
"bugs": {
|
|
84
84
|
"url": "https://discord.gg/gm3mJwcNw8"
|
|
85
85
|
},
|
|
@@ -93,4 +93,4 @@
|
|
|
93
93
|
],
|
|
94
94
|
"types": "dist/index.d.ts",
|
|
95
95
|
"packageManager": "yarn@1.22.22+sha512.a6b2f7906b721bba3d67d4aff083df04dad64c399707841b7acf00f6b133b7ac24255f2652fa22ae3534329dc6180534e98d17432037ff6fd140556e2bb3137e"
|
|
96
|
-
}
|
|
96
|
+
}
|