I am seeing issue that ids reported by emulator and device are different. I do have different android versions on them.
dump shows at pastebin dump outputs for emulator and device and the screen shots are here emulator http://imagebin.org/271953 http://imagebin.org/271953 and device http://imagebin.org/271954 http://imagebin.org/271954
Note that emulator has android 4.2.2 api 17 while device has android 4.2.1. I though feel both are API 17 should they should be considered same. I did not spot 4.2.1 platform in android sdk manager.
Also -F option to dump does not work on non-developer device (not rooted). How to then test in development devices is there some setting ?
When I did the dump -ViF on cyanogenmod rooted device I was got below results. I also checked using
(eval $(adb shell getprop | dos2unix | egrep '\[ro\.secure]|\[ro\.debuggable]' | sed 's/\./_/g; s/]: /=/g; s/[][]//g'); [[ 1 == $ro_secure && 0 == $ro_debuggable ]] && echo "System is secure: AVC won't work" || echo "System is not secure: AVC will work")
System is not secure: AVC will work
mitenm@mitendebian:~$ dump -ViF
Connecting to a device with serialno=.* with a timeout of 60 secs...
Connected to device with serialno=.*
Actual device serialno=0009cdf44f784f
Traceback (most recent call last):
File "//home/mitenm/testing/AndroidViewClient-master/AndroidViewClient/tools/dump", line 134, in <module>
vc = ViewClient(*ViewClient.connectToDeviceOrExit(**kwargs1), **kwargs2)
File "/home/mitenm/testing/AndroidViewClient-
master/AndroidViewClient/src/com/dtmilano/android/viewclient.py", line 1219, in __init__
'tcp:%d' % self.remotePort])
File "/usr/local/lib/python2.7/subprocess.py", line 537, in check_call
retcode = call(*popenargs, **kwargs)
File "/usr/local/lib/python2.7/subprocess.py", line 524, in call
return Popen(*popenargs, **kwargs).wait()
File "/usr/local/lib/python2.7/subprocess.py", line 711, in __init__
errread, errwrite)
File "/usr/local/lib/python2.7/subprocess.py", line 1308, in _execute_child
raise child_exception
OSError: [Errno 2] No such file or directory
I have ANDROID_VIEW_CLIENT_HOME env var set.
I was trying -F option so I could get R.id which I could then use in my test program. can one point me an example of it. It seems that -F will work well only with emulator so better live with no_id rather than R.id.
Also if I want to test android service (not Activities) then can I still use androidviewclient ? if so please provide link to example.
can we also do screen capture and write to files like in monkeyrunner ?
Regards,
Miten.