.setGeolocation() 編集の提案
モバイルデバイスの現在の位置情報を設定します。
使用方法
.appium.setGeolocation({latitude, longitude, altitude}, [callback])
例
module.exports = {
'set geolocation to Tokyo, Japan': function (app) {
app
.appium.setGeolocation({latitude: 35.689487, longitude: 139.691706, altitude: 5});
},
'set geolocation to Tokyo, Japan with ES6 async/await': async function (app) {
await app.appium.setGeolocation({latitude: 35.689487, longitude: 139.691706});
}
};
パラメータ
名前 | 型 | 説明 |
---|---|---|
coordinates オプション |
オブジェクト |
|
callback オプション |
関数 | コマンドが完了したときに呼び出されるオプションのコールバック関数。 |