摘要: android手机连接ubuntu系统后,执行adb root 出现error:insufficient permissions for devices的问题后 执行:export 找到sdk的环境变量:/usr/local/adt-bundle-linux-x86_64-20131030/sdk/ 阅读全文
posted @ 2017-06-02 17:03 魅力咔咔 阅读(209) 评论(0) 推荐(0) 编辑
摘要: var x= 10if(x>=0){ scala.math.sqrt(x)}else{ throw new IllegalArgumentException("the value should not be negative")}if else表达式的值为res1: Double = 3.16227 阅读全文
posted @ 2017-05-26 21:57 魅力咔咔 阅读(1648) 评论(0) 推荐(0) 编辑
摘要: var list=List("Mary","Tom","Mike")println("***********for 第一种写法************")for(s <-list) println(s)println("***********for 第二种写法************")for{ s 阅读全文
posted @ 2017-05-26 21:22 魅力咔咔 阅读(372) 评论(0) 推荐(0) 编辑
摘要: def sum(args: Int*) = {var result=0for(arg <- args) result+=arg result}sum(1,2,3) 阅读全文
posted @ 2017-05-26 21:19 魅力咔咔 阅读(1796) 评论(0) 推荐(0) 编辑
摘要: 在windows下:adb shell dumpsys activity | findstr "mFocusedActivity" 在linux下:adb shell dumpsys activity | grep "mFocusedActivity" 在uiautomator的java代码中执行该 阅读全文
posted @ 2017-05-21 11:07 魅力咔咔 阅读(2140) 评论(0) 推荐(0) 编辑
摘要: 如果把python的UIautomator用类封装后,在整个case的过程中,一定要使用launcher来启动应用,那么在launcher实现类的init方法中加入watcher,整个case就都会受到该watcher的影响,不用非得把wather加在prepare中。 实现方法如下: def __ 阅读全文
posted @ 2017-05-15 21:49 魅力咔咔 阅读(1080) 评论(0) 推荐(0) 编辑
摘要: 例如:adb shell sendevent /dev/input/event3 1 $((0xca)) 1上面语句中含有$((0xca)) ,执行Runtime.getRuntime().exec("sendevent /dev/input/event3 1 $((0xca)) 1"),不会报错, 阅读全文
posted @ 2017-05-10 12:22 魅力咔咔 阅读(1687) 评论(0) 推荐(0) 编辑
摘要: 1、javascript的Dom对象动态事件绑定注意以下2点,如:document.getElementById("id名称").addListenerEvent("事件名称",function(){代码},false),动态绑定事件,事件名称不加on,如:click,mouseover等。 (1) 阅读全文
posted @ 2017-05-07 10:48 魅力咔咔 阅读(353) 评论(0) 推荐(0) 编辑
摘要: 据我目前接触到的传多个参数的方案有三种。 第一种方案 DAO层的函数方法 ? 1 Public User selectUser(String name,String area); ? 1 Public User selectUser(String name,String area); ? 1 Pub 阅读全文
posted @ 2017-04-13 22:30 魅力咔咔 阅读(279) 评论(0) 推荐(0) 编辑