[Tutorial] How to run tests on real Android device remotely through Wi-Fi


#1

1. Connect device to computer via USB.
2. Make sure device and computer are connected to the same Wi-Fi.
3. Run this command to restart adb and make it work over tcpip:

adb tcpip 5555

4. Disconnect device
5. Get IP address of your phone (“Settings” -> Wifi -> “Your connected network” -> Your IP address")
6. Run this command to connect adb to your device over Wi-Fi using IP address:

adb connect <your phones ip address>

7. Verify, that adb works remotely:

adb devices

8. Run tests over Wi-Fi!

Source: http://qaautomationworld.blogspot.com/2014/06/appium-executing-test-throgh-wi-fi-on-real-devies.html


How to run tests on real Android device remotely through Wi-Fi(Without connecting thourgh USB once)
#2

this is sweet. one small typo though. “adb device” should be “adb devices”


#3

You are right, thanks! Fixed :smile:


#4
Hi Kirill
Thanks for sharing the info :-)

#5

Hi @kirill,Have u ran an appium test wirelessly on iPhone device?

@jonahss Any idea if this can be achieved?As the Xcode doesn’t provide search service


#6

I haven’t seen anything saying it can be done on iOS, but I’m not certain :wink:


#7

Yeah, I think the same way as well.


#8

hi @kirill

It is possible to connect an android device from different network ?


#9

I get error when i follow above steps: unable to connect to 172.26.0.127:5555: cannot connect to 172.26.0.127:5555: No
connection could be made because the target machine actively refused it. (10061)
Any idea how can i solve this?


#10

I am getting the same error as well.

unable to connect to 192.168.5.95:5555: cannot connect to 192.168.5.95:5555: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond. (10060).

NEED HELP here!


#11

easy to folow, it works like a charm!


#12

i got the same error


#13

may be your system firewall is blocking the incoming connection from device , please check once the Inbound and outbound rule for the opened port


#14

may be your system firewall is blocking the incoming connection from device , please check once the Inbound and outbound rule for the opened port


#15

Thanks a lot for the info!! It works


#16

Hi
I have tried to connect my android device over wifi
Able to connect using the adb commands but when i run the test script in eclipse the appium server automatically kills my adb server saying adb server out of date
After that the appium server is not able to detect my device.
Can any one help


#17

Thanks @kirill for this information. :slight_smile:


#18

Worked so easily. Thanks!