質問するログイン新規登録

Q&A

0回答

1329閲覧

Appium Inspectorでアプリの画面が表示・更新されません

tymamoru

総合スコア0

Appium

Appiumは、アプリなどのテスト自動化を実現するテストフレームワークの一つ。JS FoundationのOSSで、元々のアプリのソースを変えることなくテストを実行できます。テストスクリプトはSelenium APIに準じており、様々な言語のバインディングがあります。

iOS

iOSとは、Apple製のスマートフォンであるiPhoneやタブレット端末のiPadに搭載しているオペレーションシステム(OS)です。その他にもiPod touch・Apple TVにも搭載されています。

0グッド

0クリップ

投稿2022/05/02 12:18

0

0

□やろうとしていること
appium inspectorを使ってiOSアプリケーションの要素等の情報を取得する

□困っていること
iOSシミュレータが表示している画面がappium inspectorに表示されない

□環境
Appium Server GUI v1.22.3
Appium Inspector v2022.4.1

□事象
appium serverを起動し、appium inspectorで「セッションを開始する」ボタンを押した後、
画面上部に「Native App Mode」「Select Elements」「Refresh Source & Screenshot」等のボタンは表示されるのですが、画面左には更新マークが回った状態が続いて、
いつまで経ってもアプリケーションの画面が表示されません。

10回に1回の頻度で表示されることもあるのですが、
その場合でもiOSシミュレータ上でアプリケーションの画面を遷移してから
appium inspectorで「Refresh Source & Screenshot」を押すと、
画面左に更新マークが回った状態が続いて、シミュレータが表示している画面に切り替わりません。

イメージ説明

capabilities

1{ 2 "appium:udid": "xxxxx", 3 "platformName": "iOS", 4 "appium:platformVersion": "15.4", 5 "appium:deviceName": "iPhone 11", 6 "appium:wdaStartupRetries": "4", 7 "appium:iosInstallPause": "8000", 8 "appium:wdaStartupRetryInterval": "20000", 9 "appium:noReset": true, 10 "appium:app": "xxxxx.app" 11}

Appium のログ

[info] [WD Proxy] connect ECONNREFUSED 127.0.0.1:8100 [debug] [W3C (ad7a7a2d)] Encountered internal error running command: UnknownError: An unknown server-side error occurred while processing the command. Original error: Could not proxy command to the remote server. Original error: connect ECONNREFUSED 127.0.0.1:8100 [debug] [W3C (ad7a7a2d)] at JWProxy.command (/Applications/Appium Server GUI.app/Contents/Resources/app/node_modules/appium/node_modules/appium-base-driver/lib/jsonwp-proxy/proxy.js:274:13) [debug] [W3C (ad7a7a2d)] at processTicksAndRejections (internal/process/task_queues.js:85:5) [info] [HTTP] <-- GET /wd/hub/session/ad7a7a2d-ed5b-4e10-90a7-b5c2f515b82f/window/rect 500 8 ms - 683 [info] [HTTP]  [info] [HTTP] --> GET /wd/hub/session/ad7a7a2d-ed5b-4e10-90a7-b5c2f515b82f/source [info] [HTTP] {} [debug] [W3C (ad7a7a2d)] Calling AppiumDriver.getPageSource() with args: ["ad7a7a2d-ed5b-4e10-90a7-b5c2f515b82f"] [debug] [XCUITest] Executing command 'getPageSource' [debug] [WD Proxy] Matched '/source?scope=AppiumAUT' to command name 'getPageSource' [debug] [WD Proxy] Proxying [GET /source?scope=AppiumAUT] to [GET http://127.0.0.1:8100/session/79E6F63F-6BB2-46E9-897A-C8E2CC448527/source?scope=AppiumAUT] with no body [info] [WD Proxy] connect ECONNREFUSED 127.0.0.1:8100 [debug] [W3C (ad7a7a2d)] Encountered internal error running command: UnknownError: An unknown server-side error occurred while processing the command. Original error: Could not proxy command to the remote server. Original error: connect ECONNREFUSED 127.0.0.1:8100 [debug] [W3C (ad7a7a2d)] at JWProxy.command (/Applications/Appium Server GUI.app/Contents/Resources/app/node_modules/appium/node_modules/appium-base-driver/lib/jsonwp-proxy/proxy.js:274:13) [debug] [W3C (ad7a7a2d)] at processTicksAndRejections (internal/process/task_queues.js:85:5) [info] [HTTP] <-- GET /wd/hub/session/ad7a7a2d-ed5b-4e10-90a7-b5c2f515b82f/source 500 3 ms - 683 [info] [HTTP] [info] [HTTP] --> GET /wd/hub/session/ad7a7a2d-ed5b-4e10-90a7-b5c2f515b82f/timeouts [info] [HTTP] {} [debug] [W3C (ad7a7a2d)] Calling AppiumDriver.getTimeouts() with args: ["ad7a7a2d-ed5b-4e10-90a7-b5c2f515b82f"] [debug] [XCUITest] Executing command 'getTimeouts' [debug] [W3C (ad7a7a2d)] Responding to client with driver.getTimeouts() result: {"command":3600000,"implicit":0} [info] [HTTP] <-- GET /wd/hub/session/ad7a7a2d-ed5b-4e10-90a7-b5c2f515b82f/timeouts 304 2 ms - - コード

□その他、気になっていること
原因に関係しているのかわかりませんが、Appium serverを起動した後
虫眼鏡マークを押すとappium inspectorが起動せず、chromeが起動して
appium inspectorのダウンロード画面に遷移します。
なので、インストール済みのappium inspectorを個別に起動しています。

イメージ説明

どうぞよろしくお願いします。
イタリックテキスト

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

guest

回答の取得に失敗しました

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.25%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問