最近用robotium工具做一个有学习能力的自动化monkey工具,但是遇到一个问题,我拿到当前activity的view,选择一个来访问,但是我如何标识我已经访问过这个控件了呢?通过类名,属性,位置以及getid都感觉不太靠谱。大家有什么好的建议么?
拥有18年软件开发和IT教学经验。曾任多家上市公司技术总监、架构师、项目经理、高级软件工程师等职务。 网络人气名人讲师,...
setTag
setId
Of course view.hashCode()
The two methods above are not possible because the tool needs to jump between different activities, and the view will be constantly re-created and destroyed
setTag
setId
Of course view.hashCode()
The two methods above are not possible because the tool needs to jump between different activities, and the view will be constantly re-created and destroyed