Title: Run Tests on Android Real Device · Issue #284 · NativeScript/nativescript-dev-appium · GitHub
Open Graph Title: Run Tests on Android Real Device · Issue #284 · NativeScript/nativescript-dev-appium
X Title: Run Tests on Android Real Device · Issue #284 · NativeScript/nativescript-dev-appium
Description: Platform: Nativescript Angular After the setup and initial test code generated, and editing the appium.capabilities.json to add my emulator properly, I was able to succesfully run my tests to the emulator. However, I need to be able to r...
Open Graph Description: Platform: Nativescript Angular After the setup and initial test code generated, and editing the appium.capabilities.json to add my emulator properly, I was able to succesfully run my tests to the e...
X Description: Platform: Nativescript Angular After the setup and initial test code generated, and editing the appium.capabilities.json to add my emulator properly, I was able to succesfully run my tests to the e...
Opengraph URL: https://github.com/NativeScript/nativescript-dev-appium/issues/284
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Run Tests on Android Real Device","articleBody":"Platform: Nativescript Angular\r\n\r\nAfter the setup and initial test code generated, and editing the appium.capabilities.json to add my emulator properly, I was able to succesfully run my tests to the emulator.\r\n\r\nHowever, I need to be able to run the tests to a real device connected via USB (Android). \r\n- Debugging is on\r\n\r\nI added my test device details on the capabilities json as well, so the appium.capabilities.json looks like this now:\r\n```\r\n{\r\n \"realme\": {\r\n \"platformName\": \"Android\",\r\n \"deviceName\": \"RMX1851\",\r\n \"udid\": \"a53b7a83\",\r\n \"noReset\": false,\r\n \"fullReset\": false,\r\n \"app\": \"\"\r\n },\r\n \"pixel\": {\r\n \"platformName\": \"Android\",\r\n \"platformVersion\": \"29\",\r\n \"deviceName\": \"Pixel_3a_API_29\",\r\n \"avd\": \"emulator-5554\",\r\n \"lt\": 60000,\r\n \"newCommandTimeout\": 720,\r\n \"noReset\": false,\r\n \"fullReset\": false,\r\n \"app\": \"\"\r\n }\r\n```\r\nOne for emulator and one for actual device. The emulator works just fine when running:\r\n**npm run e2e android**\r\n\r\nHowever, when I connect my actual device and run the same command. It will not be shown in the list of devices and the command defaults to the emulator as a fallback.\r\n\r\nI managed to get it to try to run to my actual device by using this command instead:\r\n**npm run e2e -- --runType=realme --ignoreDeviceController --relaxedSecurity**\r\n\r\nI can confirm that it has now successfully installed the appium service on my device, but cannot move past running my app for testing. With these errors outputted:\r\n\r\n```\r\nCapabilities found at: ********\r\nAutomation name set to: UIAutomator1 \r\nTo change automation name, you need to set it in appium capabilities!\r\nAvailable applications: [\"platforms/android/app/build/outputs/apk/debug/app-debug.apk\"]\r\nPick first application: \"platforms/android/app/build/outputs/apk/debug/app-debug.apk\"\r\nApplication full path: ****\\platforms\\android\\app\\build\\outputs\\apk\\debug\\app-debug.apk\r\nPlatform version is missing! It would be better to set it in order to use the correct device! \r\nDefault device: { name: 'RMX1851',\r\n platform: 'android',\r\n config: { density: undefined, offsetPixels: undefined } }\r\nServer args: [\"-p\",\"4723\",\"--log-level\",\"info\",\"--relaxed-security\"]\r\nStarted Server!\r\n sample scenario\r\nbefore loging . . . .\r\nSession info: \r\nundefined\r\nAppium settings: \r\nCurrent version of appium doesn't support appium settings! \r\n{\"message\":\"[execute(\\\"mobile: shell\\\",{\\\"command\\\":\\\"wm\\\",\\\"args\\\":[\\\"density\\\"]})] Not JSON response\",\"data\":\"The URL '/wd/hub/session/execute' did not map to a valid resource\"}\r\nRetry launching appium driver!\r\nAppium driver is NOT started! \r\n(node:10604) [DEP0079] DeprecationWarning: Custom inspection function on Objects via .inspect() is deprecated\r\n```\r\n\r\nAnyone has an idea how to run the tests properly on real devices? (Android / IOS).","author":{"url":"https://github.com/coderaven","@type":"Person","name":"coderaven"},"datePublished":"2020-03-16T05:56:53.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":1},"url":"https://github.com/284/nativescript-dev-appium/issues/284"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:4db2f044-32a2-36d2-810b-b0707726a4f0 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | BA76:277FD5:978E2D:CAFAED:6A5B488A |
| html-safe-nonce | 6aca2dbe6c9d766853fde16febdbe298104d8e4e5693d07e4bb7665b90911a53 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCQTc2OjI3N0ZENTo5NzhFMkQ6Q0FGQUVEOjZBNUI0ODhBIiwidmlzaXRvcl9pZCI6IjIxOTAzODUzODIzMTk0MDkyOTAiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 70c540326b195228c94ad3199d824468cd3ea8b538a2bae224ae81c2ac3d3476 |
| hovercard-subject-tag | issue:582023980 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/NativeScript/nativescript-dev-appium/284/issue_layout |
| twitter:image | https://opengraph.githubassets.com/d371f9608a4c77328c2c5e587527bd29fdb2d43cbd8291ee2174b22fe0571a35/NativeScript/nativescript-dev-appium/issues/284 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/d371f9608a4c77328c2c5e587527bd29fdb2d43cbd8291ee2174b22fe0571a35/NativeScript/nativescript-dev-appium/issues/284 |
| og:image:alt | Platform: Nativescript Angular After the setup and initial test code generated, and editing the appium.capabilities.json to add my emulator properly, I was able to succesfully run my tests to the e... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | coderaven |
| hostname | github.com |
| expected-hostname | github.com |
| None | 5290d7e14309ad1e76106a9c4237bd1041517e83ea182c8ab756752cb0c6940b |
| turbo-cache-control | no-preview |
| go-import | github.com/NativeScript/nativescript-dev-appium git https://github.com/NativeScript/nativescript-dev-appium.git |
| octolytics-dimension-user_id | 7392261 |
| octolytics-dimension-user_login | NativeScript |
| octolytics-dimension-repository_id | 58553304 |
| octolytics-dimension-repository_nwo | NativeScript/nativescript-dev-appium |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 58553304 |
| octolytics-dimension-repository_network_root_nwo | NativeScript/nativescript-dev-appium |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 9c975978430e9ad293956f2bbdaf153b1bd84a99 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width