monkeyrunner测试App求教
最近开始使用monkeyrunner测试app[size=14px]#####################[/size]# log output way#
#####################
def program_traffic():
log=open('C:\Users\guji\Desktop\log\Bug#44169.txt','w')
for loop3 in range(100):
programBack_button=device.touch(122,322,'DOWN_AND_UP')
mr.sleep(1)
print ('times==>'),loop3
print (time.strftime('%y,%m,%d %H:%M',time.localtime(time.time())))
print >> log, 'operation times==>',loop3
print >> log, time.strftime('%y,%m,%d %H:%M',time.localtime(time.time()))
log.close()
def click_action():
# x=coordinate_x_list
# y=coordinate-y_list
x_list=
y_list=
print x_list,y_list
list_index=len(x_list)
for i in range(list_index):
x=x_list
y=y_list
device.touch(x,y,'DOWN_AND_UP')
mr.sleep(2)
device.press('KEYCODE_BACK')
mr.sleep(2)
print ('Done')
但是感觉自己写的太简单了,想请教各位高手进行指点,如何能写的比较细致
大家可以给LZ一些参考的建议~~ 楼主,你贴的代码怎么看起来很屌的样子? 没有很屌啊。肯能有点凌乱吧。。。。希望大家给点建议 看不太懂。。。
页:
[1]