node-simctl
Advanced tools
Comparing version 6.3.4 to 6.4.0
@@ -46,2 +46,3 @@ "use strict"; | ||
this._udid = _lodash.default.isNil(opts.udid) ? null : opts.udid; | ||
this._devicesSetPath = _lodash.default.isNil(opts.devicesSetPath) ? null : opts.devicesSetPath; | ||
} | ||
@@ -57,2 +58,10 @@ | ||
set devicesSetPath(value) { | ||
this._devicesSetPath = value; | ||
} | ||
get devicesSetPath() { | ||
return this._devicesSetPath; | ||
} | ||
requireUdid(commandName = null) { | ||
@@ -86,3 +95,3 @@ if (!this.udid) { | ||
} = opts; | ||
args = ['simctl', subcommand, ...args]; | ||
args = ['simctl', ...(this.devicesSetPath ? ['--set', this.devicesSetPath] : []), subcommand, ...args]; | ||
env = _lodash.default.defaults(_lodash.default.mapKeys(env, (value, key) => _lodash.default.startsWith(key, SIMCTL_ENV_PREFIX) ? key : `${SIMCTL_ENV_PREFIX}${key}`), process.env); | ||
@@ -131,2 +140,2 @@ const execOpts = { | ||
//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImxpYi9zaW1jdGwuanMiXSwibmFtZXMiOlsiU0lNQ1RMX0VOVl9QUkVGSVgiLCJERUZBVUxUX09QVFMiLCJ4Y3J1biIsInBhdGgiLCJleGVjVGltZW91dCIsIkRFRkFVTFRfRVhFQ19USU1FT1VUIiwibG9nRXJyb3JzIiwiU2ltY3RsIiwiY29uc3RydWN0b3IiLCJvcHRzIiwiXyIsImNsb25lRGVlcCIsImRlZmF1bHRzRGVlcCIsImtleSIsImtleXMiLCJfdWRpZCIsImlzTmlsIiwidWRpZCIsInZhbHVlIiwicmVxdWlyZVVkaWQiLCJjb21tYW5kTmFtZSIsIkVycm9yIiwicmVxdWlyZVhjcnVuIiwiWENSVU5fQklOQVJZIiwiZSIsImV4ZWMiLCJzdWJjb21tYW5kIiwiYXJncyIsImVudiIsImFzeW5jaHJvbm91cyIsImVuY29kaW5nIiwiZGVmYXVsdHMiLCJtYX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dGhlIGVycm9ycywganVzdCB0aHJvdyBhbmQgYWxsb3cgdGhlIGNhbGxpbmdcbiAgICAgICAgLy8gY29kZSBkbyB3aGF0IGl0IHdhbnRzXG4gICAgICAgIHRocm93IGU7XG4gICAgICB9IGVsc2UgaWYgKGUuc3RkZXJyKSB7XG4gICAgICAgIGNvbnN0IG1zZyA9IGBFcnJvciBydW5uaW5nICcke3N1YmNvbW1hbmR9JzogJHtlLnN0ZGVyci50cmltKCl9YDtcbiAgICAgICAgbG9nLmRlYnVnKExPR19QUkVGSVgsIG1zZyk7XG4gICAgICAgIHRocm93IEVycm9yKG1zZyk7XG4gICAgICB9IGVsc2Uge1xuICAgICAgICBsb2cuZGVidWcoTE9HX1BSRUZJWCwgZS5tZXNzYWdlKTtcbiAgICAgICAgdGhyb3cgZTtcbiAgICAgIH1cbiAgICB9XG4gIH1cbn1cblxuXG4vLyBhZGQgYWxsIHRoZSBzdWJjb21tYW5kcyB0byB0aGUgU2ltY3RsIHByb3RvdHlwZVxuZm9yIChjb25zdCBbZm5OYW1lLCBmbl0gb2YgXy50b1BhaXJzKHN1YmNvbW1hbmRzKSkge1xuICBTaW1jdGwucHJvdG90eXBlW2ZuTmFtZV0gPSBmbjtcbn1cblxuZXhwb3J0IGRlZmF1bHQgU2ltY3RsO1xuZXhwb3J0IHsgU2ltY3RsIH07Il0sImZpbGUiOiJsaWIvc2ltY3RsLmpzIiwic291cmNlUm9vdCI6Ii4uLy4uIn0= |
@@ -41,3 +41,3 @@ import _ from 'lodash'; | ||
* then it is going to be used by `exec` and no autodetection will happen. | ||
* @property {?number} execTimeout [600000] - The maximum number of miulliseconds | ||
* @property {?number} execTimeout [600000] - The maximum number of milliseconds | ||
* to wait for single synchronous xcrun command. | ||
@@ -47,5 +47,7 @@ * @property {?boolean} logErrors [true] - Whether to wire xcrun error messages | ||
* @property {?string} udid [null] - The unique identifier of the current device, which is | ||
* going to be implictly passed to all methods, which require it. It can either be set | ||
* upon instance creation if it is already known in davnce or later when/if needed via the | ||
* going to be implicitly passed to all methods, which require it. It can either be set | ||
* upon instance creation if it is already known in advance or later when/if needed via the | ||
* corresponding instance setter. | ||
* @property {?string} devicesSetPath - Full path to the set of devices that you want to manage. | ||
* By default this path usually equals to ~/Library/Developer/CoreSimulator/Devices | ||
*/ | ||
@@ -65,2 +67,3 @@ | ||
this._udid = _.isNil(opts.udid) ? null : opts.udid; | ||
this._devicesSetPath = _.isNil(opts.devicesSetPath) ? null : opts.devicesSetPath; | ||
} | ||
@@ -76,2 +79,10 @@ | ||
set devicesSetPath (value) { | ||
this._devicesSetPath = value; | ||
} | ||
get devicesSetPath () { | ||
return this._devicesSetPath; | ||
} | ||
requireUdid (commandName = null) { | ||
@@ -117,3 +128,7 @@ if (!this.udid) { | ||
// run a particular simctl command | ||
args = ['simctl', subcommand, ...args]; | ||
args = ['simctl', | ||
...(this.devicesSetPath ? ['--set', this.devicesSetPath] : []), | ||
subcommand, | ||
...args | ||
]; | ||
// Prefix all passed in environment variables with 'SIMCTL_CHILD_', simctl | ||
@@ -120,0 +135,0 @@ // will then pass these to the child (spawned) process. |
@@ -9,3 +9,3 @@ { | ||
], | ||
"version": "6.3.4", | ||
"version": "6.4.0", | ||
"author": "https://github.com/appium", | ||
@@ -12,0 +12,0 @@ "license": "Apache-2.0", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
216347
2796