日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

Appium下载遇到的问题

發布時間:2023/12/10 编程问答 33 豆豆
生活随笔 收集整理的這篇文章主要介紹了 Appium下载遇到的问题 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

**


(Mac 版)
**

步驟:

我用的是npm 下載appium 1.6.3的版本。
1.在下載之前先要安裝brew 。

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" #下載 $ brew update #更新

下載完成后可查看是否安裝成功

brew -v

2.安裝node 和 npm

brew install node node -v brew install npm

3.使用npm來安裝appium,2017/01/03目前最新的版本是 1.6.3 ,當然也可以在 Macos下bitbucket下載appium客戶端,但是坑人的是最新版本是 1.5.3 支持的還只是 iOS10 以下的 UIAutomation 框架基礎上測試,而 iOS10 以后蘋果使用的卻是基于 XCUITest ,所以只能采用npm安裝咯。但是因為國內墻太高而使用npm卻是從國外服務器下載,有時候使用npm需要非常長的時間,更多時候是失敗,推薦使用cnpm來安裝:淘寶 NPM 鏡像 10分鐘同步npmjs.org鏡像,使用方式和npm完全一致
本人用的Shadowsocks proxy

npm install cnpm -g --registry=https://registry.npm.taobao.org npm view appium versions #查看appium所有的版本號 npm install appium-doctor#安裝appium-doctor

4.使用cnpm安裝appium和appium-doctor:

cnpm install -g appium --no-cache cnpm install -g appium cnpm install -g appium-doctor

5.檢查appium環境:

Java 環境和Android環境請自行百度安裝。推薦蟲師的博客。http://www.cnblogs.com/fnng/
6.安裝appium客戶端,上面的操作只是安裝了server端,接下來需要安裝測試代碼運行所依賴的客戶端,我們以python為例:

``` 7.對于 iOS10 以上的測試,需要下載安裝 appium-xcuitest-driver 驅動:Appium iOS driver, backed by Apple XCUITest , 當然也可以在 /usr/local/lib/node_modules/appium/node_modules/.2.5.1@appium-xcuitest-driver/WebDriverAgent/ 找到該項目,執行 carthage update , 選擇 WebDriverAgentRunner 這個target編譯即可。其他相關的安裝:

brew?install?libimobiledevice?–HEAD??#?install?from?HEAD?to?get?important?updates brew install ideviceinstaller # 只是對iOS9有用

npm?install?-g?ios-deploy????????????????#?iOS10?以后的版本安裝ios-deploy sudo gem install xcpretty # 真機需要安裝 xcpretty
“`
也可參考Appium 官方文檔https://github.com/appium/appium
安裝完成后可測試Appium是否安裝成功

問題:
1.npm 安裝時需要翻墻
2.如果有賬戶需要用sudo安裝,即需要輸入密碼,安裝命令如下:
sudo npm install -g appium
3.在安裝出錯后,需卸載appium 之后再重新安裝,卸載命令:sudo npm uninstall appium
4.遇到如下報的錯誤,可以把下載地址拷貝到瀏覽器中下載。

bogon:~xxx $ sudo npm install -g appium
/usr/local/bin/appium -> /usr/local/lib/node_modules/appium/build/lib/main.js

sqlite3@3.1.8 install /usr/local/lib/node_modules/appium/node_modules/sqlite3
node-pre-gyp install –fallback-to-build

node-pre-gyp ERR! Tried to download(undefined): https://mapbox-node-binary.s3.amazonaws.com/sqlite3/v3.1.8/node-v48-darwin-x64.tar.gz
node-pre-gyp ERR! Pre-built binaries not found for sqlite3@3.1.8 and node@6.9.5 (node-v48 ABI) (falling back to source compile with node-gyp)
ACTION deps_sqlite3_gyp_action_before_build_target_unpack_sqlite_dep Release/obj/gen/sqlite-autoconf-3150000/sqlite3.c
TOUCH Release/obj.target/deps/action_before_build.stamp
CC(target) Release/obj.target/sqlite3/gen/sqlite-autoconf-3150000/sqlite3.o
LIBTOOL-STATIC Release/sqlite3.a
CXX(target) Release/obj.target/node_sqlite3/src/database.o
../src/database.cc:133:18: warning: ‘ForceSet’ is deprecated
[-Wdeprecated-declarations]
info.This()->ForceSet(Nan::New(“filename”).ToLocalChecked(), info[0]…
^
/Users/xxx/.node-gyp/6.9.5/include/node/v8.h:2695:22: note: ‘ForceSet’ has
xxx/been explicitly marked deprecated here
bool ForceSet(Local key, Local value,
^
../src/database.cc:134:18: warning: ‘ForceSet’ is deprecated
[-Wdeprecated-declarations]
info.This()->ForceSet(Nan::New(“mode”).ToLocalChecked(), Nan::New(mo…
^
/Users/xxx/.node-gyp/6.9.5/include/node/v8.h:2695:22: note: ‘ForceSet’ has
been explicitly marked deprecated here
bool ForceSet(Local key, Local value,
^
../src/database.cc:144:9: warning: unused variable ‘status’ [-Wunused-variable]
int status = uv_queue_work(uv_default_loop(),
^
../src/database.cc:230:9: warning: unused variable ‘status’ [-Wunused-variable]
int status = uv_queue_work(uv_default_loop(),
^
../src/database.cc:525:9: warning: unused variable ‘status’ [-Wunused-variable]
int status = uv_queue_work(uv_default_loop(),
^
../src/database.cc:625:9: warning: unused variable ‘status’ [-Wunused-variable]
int status = uv_queue_work(uv_default_loop(),
^
6 warnings generated.
CXX(target) Release/obj.target/node_sqlite3/src/node_sqlite3.o
CXX(target) Release/obj.target/node_sqlite3/src/statement.o
../src/statement.cc:103:18: warning: ‘ForceSet’ is deprecated
[-Wdeprecated-declarations]
info.This()->ForceSet(Nan::New(“sql”).ToLocalChecked(), sql, ReadOnly);
^
/Users/xxx/.node-gyp/6.9.5/include/node/v8.h:2695:22: note: ‘ForceSet’ has
been explicitly marked deprecated here
bool ForceSet(Local key, Local value,
^
../src/statement.cc:118:9: warning: unused variable ‘status’ [-Wunused-variable]
int status = uv_queue_work(uv_default_loop(),
^
../src/statement.cc:322:5: warning: unused variable ‘status’ [-Wunused-variable]
STATEMENT_BEGIN(Bind);
^
../src/macros.h:125:9: note: expanded from macro ‘STATEMENT_BEGIN’
int status = uv_queue_work(uv_default_loop(), \
^
../src/statement.cc:370:5: warning: unused variable ‘status’ [-Wunused-variable]
STATEMENT_BEGIN(Get);
^
../src/macros.h:125:9: note: expanded from macro ‘STATEMENT_BEGIN’
int status = uv_queue_work(uv_default_loop(), \
^
../src/statement.cc:438:5: warning: unused variable ‘status’ [-Wunused-variable]
STATEMENT_BEGIN(Run);
^
../src/macros.h:125:9: note: expanded from macro ‘STATEMENT_BEGIN’
int status = uv_queue_work(uv_default_loop(), \
^
../src/statement.cc:504:5: warning: unused variable ‘status’ [-Wunused-variable]
STATEMENT_BEGIN(All);
^
../src/macros.h:125:9: note: expanded from macro ‘STATEMENT_BEGIN’
int status = uv_queue_work(uv_default_loop(), \
^
../src/statement.cc:601:5: warning: unused variable ‘status’ [-Wunused-variable]
STATEMENT_BEGIN(Each);
^
../src/macros.h:125:9: note: expanded from macro ‘STATEMENT_BEGIN’
int status = uv_queue_work(uv_default_loop(), \
^
../src/statement.cc:724:5: warning: unused variable ‘status’ [-Wunused-variable]
STATEMENT_BEGIN(Reset);
^
../src/macros.h:125:9: note: expanded from macro ‘STATEMENT_BEGIN’
int status = uv_queue_work(uv_default_loop(), \
^
8 warnings generated.
SOLINK_MODULE(target) Release/node_sqlite3.node
clang: warning: libstdc++ is deprecated; move to libc++ with a minimum deployment target of OS X 10.9
COPY /usr/local/lib/node_modules/appium/node_modules/sqlite3/lib/binding/node-v48-darwin-x64/node_sqlite3.node
TOUCH Release/obj.target/action_after_build.stamp

appium-chromedriver@2.9.4 install /usr/local/lib/node_modules/appium/node_modules/appium-chromedriver
node install-npm.js

info Chromedriver Install Installing Chromedriver version ‘2.25’ for platform ‘mac’ and architecture ‘64’
info Chromedriver Install Opening temp file to write chromedriver_mac64 to…
info Chromedriver Install Downloading https://chromedriver.storage.googleapis.com/2.25/chromedriver_mac64.zip…
info Chromedriver Install Writing binary content to /usr/local/lib/node_modules/appium/node_modules/appium-chromedriver/201721-2404-hg3ybx.ldznx0qkt9/chromedriver_mac64.zip…
info Chromedriver Install Extracting /usr/local/lib/node_modules/appium/node_modules/appium-chromedriver/201721-2404-hg3ybx.ldznx0qkt9/chromedriver_mac64.zip to /usr/local/lib/node_modules/appium/node_modules/appium-chromedriver/201721-2404-hg3ybx.ldznx0qkt9/chromedriver_mac64
info Chromedriver Install Creating /usr/local/lib/node_modules/appium/node_modules/appium-chromedriver/chromedriver/mac…
info Chromedriver Install Copying unzipped binary, reading from /usr/local/lib/node_modules/appium/node_modules/appium-chromedriver/201721-2404-hg3ybx.ldznx0qkt9/chromedriver_mac64/chromedriver…
info Chromedriver Install Writing to /usr/local/lib/node_modules/appium/node_modules/appium-chromedriver/chromedriver/mac/chromedriver…
info Chromedriver Install /usr/local/lib/node_modules/appium/node_modules/appium-chromedriver/chromedriver/mac/chromedriver successfully put in place

appium-selendroid-driver@1.4.3 install /usr/local/lib/node_modules/appium/node_modules/appium-selendroid-driver
node ./bin/install.js

dbug AndroidDriver Getting Java version
info AndroidDriver Java version is: 1.8.0_65
info Selendroid Ensuring /usr/local/lib/node_modules/appium/node_modules/appium-selendroid-driver/selendroid/download exists
info Selendroid Downloading Selendroid standalone server version 0.17.0 from http://repo1.maven.org/maven2/io/selendroid/selendroid-standalone/0.17.0/selendroid-standalone-0.17.0-with-dependencies.jar –> /usr/local/lib/node_modules/appium/node_modules/appium-selendroid-driver/selendroid/download/selendroid-server-7cf7163ac47f1c46eff95b62f78b58c1dabdec534acc6632da3784739f6e9d82.jar

總結

以上是生活随笔為你收集整理的Appium下载遇到的问题的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。