@@ -63,6 +63,9 @@ const DEFAULT_OPTS = {
63
63
* command input and outputs.
64
64
* @property {string|string[] } [architectures] - One or more architecture names to be enforced while
65
65
* executing xcrun. See https://github.com/appium/appium/issues/18966 for more details.
66
+ * @property {number } [timeout] - The maximum number of milliseconds
67
+ * to wait for single synchronous xcrun command. If not provided explicitly, then
68
+ * the value of execTimeout property is used by default.
66
69
*/
67
70
68
71
/**
@@ -72,7 +75,7 @@ const DEFAULT_OPTS = {
72
75
* the instance to automatically detect the full path to `xcrun` tool and to throw
73
76
* an exception if it cannot be detected. If the path is set upon instance creation
74
77
* then it is going to be used by `exec` and no autodetection will happen.
75
- * @property {number } [execTimeout=600000] - The maximum number of milliseconds
78
+ * @property {number } [execTimeout=600000] - The default maximum number of milliseconds
76
79
* to wait for single synchronous xcrun command.
77
80
* @property {boolean } [logErrors=true] - Whether to wire xcrun error messages
78
81
* into debug log before throwing them.
@@ -175,6 +178,7 @@ class Simctl {
175
178
encoding,
176
179
logErrors = true ,
177
180
architectures,
181
+ timeout,
178
182
} = opts ?? { } ;
179
183
// run a particular simctl command
180
184
args = [
@@ -196,7 +200,7 @@ class Simctl {
196
200
encoding,
197
201
} ;
198
202
if ( ! asynchronous ) {
199
- execOpts . timeout = this . execTimeout ;
203
+ execOpts . timeout = timeout || this . execTimeout ;
200
204
}
201
205
const xcrun = await this . requireXcrun ( ) ;
202
206
try {
0 commit comments