As of May 31, 2023, we have updated our Code of Conduct.

Questions tagged [android-uiautomator]

The uiautomator testing framework lets you test your user interface (UI) efficiently by creating automated functional UI testcases that can be run against your app on one or more devices.

Filter by
Sorted by
Tagged with
0 votes
0 answers
35 views

is there any alternate way to install appium uiautomator2 driver apart from running "appium driver install uiautomator2" from CLI

I am starting with a new project setup for mobile test automation with appium-java. I have installed appium server in my machine but facing a problem while installing appium drivers for Android and ...
puneeth chidura's user avatar
0 votes
0 answers
29 views

UiAutomator UiSelector childSelector or equivalent but with advanced conditionals?

I'm struggling to identify any support to negate expressions when using the Android UiAutomator API. I currently have a RecyclerView with several ViewGroup nested to it, and they can be either ...
Lautenschlager's user avatar
0 votes
0 answers
43 views

Appium exited before timeout error on every second execution in WDIO

I am running a test suite using WebDriverIO and Appium to automate Android app testing. My test suite runs successfully on the first execution, but on the second execution, I am getting an "...
Adar Sönmez's user avatar
0 votes
0 answers
9 views

While running weditor getting 407 Proxy Authentication Required error

Always getting proxy authentication error although I have done proxy setup. Below is the error which I am getting. Weditor is a python package - https://pypi.org/project/weditor/ PS C:\workspace\xyzz\...
RejeeshChandran's user avatar
0 votes
0 answers
13 views

Android Uiautomator problem about instance selector and dump

When I use UIautomator and I want to locate widget by instance and class now I dump the xml like <> <> systemui textview <> current app text view (target) <> That's to say, ...
yuxuan xu's user avatar
0 votes
0 answers
9 views

Gradle task `connectedXXXAndroidTest` doesn't perform test cases under 1 specific directory

The instrument test file structure in AD is like this: com.companyname.propjectname integrationtest: 20 test cases systemtest: groupA: 30 test cases [x] groupB: 50 + test cases ...
Zhou Haibo's user avatar
  • 1,561
0 votes
0 answers
5 views

Check view postion towards other view using UI Automator

Basically the question. I have created a tile for a WearOS, with two elements, and i want to check their positions towards each other in simple test - view X should be on the left of Y, and Y should ...
AShX's user avatar
  • 438
0 votes
0 answers
59 views

Getting error -Djava.ext is not supported. Use -classpath instead

I am using java 8 and trying to run uiautomatorviewer.bat of Appium tool but I'm getting below error. Djava.ext.dirs=..\lib\x86_64;..\lib is not supported. Use -classpath instead. Error: Could not ...
Aishwarya surve's user avatar
1 vote
0 answers
70 views

How do I get the parent UiSelector starting at its child?

Note: Working with Java 11 and Appium. I am trying to get a MobileElement for an appium test suite using Android UiAutomators. Specifically I need to scroll to one so I am condtructing the locator ...
cdub's user avatar
  • 300
1 vote
1 answer
99 views

Cannot set AndroidDriver. AndroidUIAutomator2 cannot start a new session, with response code 500

I'm using Appium 2.0.0-beta.61 and AndroidUiAutomator2, and when I try to start the Android driver, it fails, returning Response Code 500. I tried removing the Appium server app from the device and ...
Grzeche's user avatar
  • 11
0 votes
1 answer
18 views

BaselineProfile for Phone/Tablet

How can I deal with the Baseline Profile generation when I have different code running depending on the device? For example, I have some kind of method like this: public static String runCode() { ...
Carlos Lopez's user avatar
0 votes
0 answers
43 views

Android App test automation using appium, selenium and UIAutomatorviewer

I am facing a problem on android application test automation using appium, selenium and uiautomatorviewer. I would like to ask what are other ways/alternatives to automate the app when the app has ...
fahad's user avatar
  • 31
0 votes
0 answers
20 views

Android UIAutomator: How to get current running test method's name in UI Test

In Xcode we use self.name to get class name combing method name for current performing UI test case. I'm wondering what is the equivalent in Android UI Test with UIAutomator framework? This is what PO ...
Zhou Haibo's user avatar
  • 1,561
1 vote
1 answer
50 views

Error on android using uiautomator2 on Pydroid3

I'm trying to automate tasks on Android, but when I run my code on Pydroid3 on Android, it return me a error... My device is a Asus Zenfone Selfie 4 I'dont understand this error because the error is ...
Gabriel Garcia's user avatar
0 votes
0 answers
19 views

UiSelector descriptionContains does not work

I am trying to write simile UiAutomator test. When I inspect screen either throung layout inspector or UiAutomator. I see edit text with content description that says "Work Email" However I ...
Subodh Nijsure's user avatar
0 votes
0 answers
33 views

UIAutomatorViewer doesn't work with Android 8

I'm developing automatization programm with ADB. I use UIAutomatorViewer to find elements on my phone, that has Android 7.1.2 version. It works fine with it, but recently I needed to use another phone ...
AlKaine's user avatar
0 votes
2 answers
307 views

Error message when trying to install driver on Appium cli

I've recently installed the Appium cli executing the command found on the official documentation: npm install -g appium When the installation ended successfully, I've tried to install the UI ...
Alessandro Violante's user avatar
0 votes
0 answers
32 views

Click on a cross (x) button inside of a search edit text view

I want to click on the cross (x) button which is a part of a search edit text view (search text field). The button doesn't have any resource Id or element. I tried the following ways to interact: ...
Adam Jensen's user avatar
0 votes
0 answers
48 views

Get complete xml dump of a scrollable app page at once

I want to get the complete xml dump of a scrollable page of an android app running on emulator. I tried using Appium's getPageSource(), but it gives only the viewable content dump. I also tried using '...
Anchal Kumari's user avatar
0 votes
0 answers
17 views

What is alternative way to run a test repeatedly in Android Studio?

In Xcode, we could run a test repeatedly. I want to know what is the alternative in Android Studio. Well, new to Android, our project is using UIAutomator for UI test. And I'd like to know if there is ...
Zhou Haibo's user avatar
  • 1,561
0 votes
0 answers
11 views

How to reach file in Android test under the first page in Android App using Kotlin?

I write Kotlin test and I need to open the file after the file "Node Apr 23, 2017.pdf". But I can reach only the files from first page in the Download folder, by words "first page" ...
py_mc's user avatar
  • 41
0 votes
0 answers
81 views

Pthon3 uiautomator2 : uiautomator2.exceptions.NullPointerExceptionError while useing dump_hierarchy function

I am trying to dump info by using dump_hierarchy over uiautomator2. But NullPointerExceptionError occurred. When it occurred it can be fixed by itself. Try it again and again. ...
赵小甲's user avatar
0 votes
0 answers
198 views

Appium Uiautomator keeps crashing due to mjpegserver crash

Appium logs: I ran this test on a real android device. I changed the language and the country of the device using appium settings app, and some apps got updated like google play services. After that ...
ABHINAV ANAND's user avatar
0 votes
0 answers
39 views

Can't find some compose using UiAutomator

I have the following code: @Composable fun Home(navController: NavHostController) { val itemsList = (1..100).toList() val itemsIndexedList = listOf("A", "B", "C")...
SageJustus's user avatar
0 votes
0 answers
93 views

How to find an item having same id by index from a list view

In XCTest, we could find a specific UI element by index, for instance, a list view has reused item with same identifier. app.staticTexts.matching(identifier: "BETTER").element(boundBy: 1) ...
Zhou Haibo's user avatar
  • 1,561
0 votes
1 answer
264 views

How does Appium/UiAutomator actually see composables?

I have been rewriting my app to Jetpack Compose, and I already have existing Appium tests. After rewriting (using testTag modifiers to replace what used to be resource IDs) all of my tests work fine. ...
Jason Toms's user avatar
0 votes
0 answers
192 views

PytestUnhandledThreadExceptionWarning during uiautomator dump

In my pytest I am actually not doing much just making uiautomator dump and pull the created file to local path, but it does give me the below warning: copporcomm_test/access_try.py::...
FotisK's user avatar
  • 1,027
0 votes
0 answers
72 views

How to use "longClickGesture" in appium UiAutomator2 with x and y coordinates?

I'm fairly new to Appium, and trying to understand mobile gestures using UIautomator2 . The official documentation provides JAVA syntax on how to use the "longClickGesture" when element id ...
visha rathi's user avatar
0 votes
1 answer
107 views

It doesn't always scroll to the same place, Appium Android

I am using the following method while scrolling android. but It doesn't always scroll to the same place, even though it's on the same page. what would be the reason. public void ScrollToCampaignNotice(...
Onurcan's user avatar
  • 21
0 votes
0 answers
49 views

How to get the text value of a focused /selected item with uiautomator python wrapper

I need to get the text value of the focused/ selected item with uiautomator python wrapper. The framework needs to get the node with value ( focused = true) and return first text value of any of the ...
Chopin's user avatar
  • 39
3 votes
0 answers
497 views

How to set id in Jetpack Compose for Appium and UIAutomator (Xpath issue)

I am using Jetpack Compose and Appium with UIAutomator. I would like to set a unique id for the Composables instead of showing the Xpath because of: Using XPath locators is not recommended and can ...
Targetbus12's user avatar
0 votes
0 answers
33 views

how we can click on search button present on the keyboard of android mobile using UIautomator Framework

I was automation the script to search videos and I am unable to click on search button present on keyboard I tried device.pressEnter() and device.pressSearch()method of uiautomator
piyush's user avatar
  • 1
0 votes
0 answers
57 views

How can I start Instagram with my previously logged in account? Python, Appium

I'm automating processes in Instagram, and I would like to bypass a block that Instagram has for this type of actions. My code contemplates the login but the problem is that by repeating it many times,...
Lucho Piehl's user avatar
0 votes
1 answer
87 views

UiDevice.hasObject method takes too long time in UiAutomator

I write a auto testcase to test Tiktok In the testcase, before I switch to next video, I will check the current video type, and do something. Log.i(TAG, "check if it's a vr video") val ...
Kevin Ding's user avatar
1 vote
1 answer
257 views

What is the function of uiautomator apks present on the python wrapper for uiautomator 2

I am trying to read and understand how python wrapper for uiautomator2 works. What is the function of uiautomator apks present inside libs and how does this whole framework work? Also, where did they ...
Chopin's user avatar
  • 39
0 votes
1 answer
125 views

Where can I find examples of testing interactions with android homescreen widgets?

I see very little information on how to test RemoteViews. For example, I have used UiAutomator to place an app widget on the homescreen and now i want to test if it updates correctly when I click on ...
mars8's user avatar
  • 698
0 votes
0 answers
151 views

Why am i getting this exception in firebase crashlytics? IllegalStateException : UiAutomation not connected

I know that Google console runs Uiautomation tests(prelaunch). However crash logs that i receive in firebase crashlytics do not seem to be related to the prelaunch process, because this exception ...
The Dongster's user avatar
0 votes
0 answers
18 views

Pytest assertion that submit button is not present

I’m trying to write a test for test case where submit button is not present in application. I wrote this assertion: assert self.pages.is_submit_button_displayed() is False is_submit_button_displayed ...
Shreya Goyal's user avatar
0 votes
1 answer
148 views

How to simulate app kill using either espresso or uiautomator?

We have a app that has some data stored in singleton classes. so, the data changes only after the app is killed. so,We have a usecase that require app kill in the middle of automation testing. How to ...
Venkataramanan's user avatar
0 votes
0 answers
81 views

UIdevice.dumpWindowHierarchy() not working for WebView changes

I am using method dumpWindowHierarchy() to get the Hierarchy dump for my automation tests. It is working fine and giving me the hierarchy for the web-view window but the problem is when there is ...
FiXiT's user avatar
  • 759
3 votes
0 answers
95 views

adb uiautomator dump returns 0,0 bounds for clickable button

I'm trying to automate sending a picture on snapchat, using python and uiautomator dump. When I have taken the picture and am ready to click the send button, the uiautomator dump returns the button ...
NielsNasibal's user avatar
0 votes
1 answer
184 views

Stop an Android app with UiAutomator/UiDevice

My app is bound to the service of another app (I don't have the source code of this one). I want to test the case when the binding with the service is broken. For this, I have a manual test where I ...
vrfrom07's user avatar
0 votes
0 answers
44 views

Is there any alternative way for LongpressGesture in Android Testing using POM model

I am getting following error while doing Android Testing using Appium(Java) "java.lang.ClassCastException: class jdk.proxy2.$Proxy14 cannot be cast to class org.openqa.selenium.remote....
Yesh's user avatar
  • 11
1 vote
1 answer
275 views

unable to start uiautomatorviewer in windows due to classpath error

I am unable to start uiautomatorviewer due to below error: C:\Users\176226\AppData\Local\Android\Sdk\tools\bin>uiautomatorviewer -Djava.ext.dirs=..\lib\x86_64;..\lib is not supported. Use -...
rohini dingankar's user avatar
0 votes
0 answers
42 views

Android UIAutomator long click of exact time ms on device screen

I use this but its not working as expected: fun UiDevice.press(x: Int, y: Int, time: Int) { swipe(x, y, x, y, time / 5) } I am getting random lengths of press events. Is there any better solution ...
Renetik's user avatar
  • 5,770
0 votes
2 answers
408 views

Appium-UIAutomator2-Java: the same code works directly from test and doesn't work from a function called in test

I'm writing mobile test using Appium+UIAutomator2+Java+JUnit5. The point is when I'm calling the code from the test everything works fine and all elements can be located. When I'm using the same code ...
Anton's user avatar
  • 1
0 votes
0 answers
66 views

UiAutomator 2.1.2 waitForExist

I'm trying to do some tests in my application using bluestacks 5 with nodejs and https://www.npmjs.com/package/uiautomator-server but when I send await device.waitForExists( { description: 'Back', ...
Kelvin Primo's user avatar
1 vote
3 answers
6k views

Error installing uiautomator2 driver with Appium

I am pretty new to appium and I tried installing the uiautomator2 driver to the latest appium version 2.0.0-beta.41 via the command appium driver install uiautomator2 I always get this output: > ...
Scuba's user avatar
  • 73
0 votes
0 answers
50 views

Android UiAutomator: How to wait for WIFI / Network to turn on?

When running a JUnit UI test, after turning on the WIFI, it takes about 2/3 seconds to actually come on. How can I wait for the WIFI to come back on without doing a thread.sleep(3000)? It is possible ...
Kes Walker's user avatar
  • 1,084
0 votes
0 answers
80 views

Appium selector methods: Appium Inspector and UIAutomatorViewer throwing errors

I am trying to use Appium together with robot framework to automate some tests for android-bluetooth connectivity. Currently, I am following a similar thought-architecture to something I've worked on ...
Jakob Wirén's user avatar

1
2 3 4 5
18