Macaca 等待机制
工具软件自己的问题
不支持面向页面设计模式 , 更不用说面向组件
搭建环境
C:\Windows\system32>cnpm install macaca-electron -g
Downloading macaca-electron to C:\Users\zhangqiang\AppData\Roaming\npm\node_modules\macaca-electron_tmp
Copying C:\Users\zhangqiang\AppData\Roaming\npm\node_modules\macaca-electron_tmp\_macaca-electron@1.1.6@macaca-electron to C:\Users\zhangqiang\AppData\Roaming\npm\node_modules\macaca-electron
Installing macaca-electron's dependencies to C:\Users\zhangqiang\AppData\Roaming\npm\node_modules\macaca-electron/node_modules
[1/7] co@^4.6.0 installed at node_modules\_co@4.6.0@co
[2/7] webdriver-dfn-error-code@^1.0.3 installed at node_modules\_webdriver-dfn-error-code@1.0.4@webdriver-dfn-error-code
[3/7] driver-base@^0.1.0 installed at node_modules\_driver-base@0.1.4@driver-base
[4/7] xlogger@^1.0.0 installed at node_modules\_xlogger@1.0.6@xlogger
[5/7] selenium-atoms@~1.0.1 installed at node_modules\_selenium-atoms@1.0.2@selenium-atoms
[6/7] electron-prebuilt@^0.37.6 installed at node_modules\_electron-prebuilt@0.37.8@electron-prebuilt
[7/7] macaca-utils@~0.1.8 installed at node_modules\_macaca-utils@0.1.9@macaca-utils
execute post install 1 scripts...
[1/1] scripts.postinstall electron-prebuilt@^0.37.6 run "node install.js"
Downloading electron-v0.37.8-win32-x64.zip
[============================================>] 100.0% of 49.65 MB (4.84 MB/s)
[1/1] scripts.postinstall electron-prebuilt@^0.37.6 finished in 23s
Recently updated (since 2017-06-19): 3 packages (detail see file C:\Users\zhangqiang\AppData\Roaming\npm\node_modules\macaca-electron\node_modules\.recently_updates.txt)
2017-06-23
→ electron-prebuilt@0.37.8 › extract-zip@1.6.5 › concat-stream@1.6.0 › readable-stream@2.3.2 › string_decoder@~1.0.0(1.0.3) (02:36:15)
2017-06-22
→ electron-prebuilt@0.37.8 › extract-zip@1.6.5 › concat-stream@1.6.0 › readable-stream@^2.2.2(2.3.2) (21:48:21)
→ electron-prebuilt@0.37.8 › extract-zip@1.6.5 › concat-stream@1.6.0 › readable-stream@2.3.2 › safe-buffer@~5.1.0(5.1.1) (04:19:28)
All packages installed (166 packages installed from npm registry, used 37s, speed 81.41kB/s, json 183(271.17kB), tarball 2.66MB)
[3/7] driver-base@^0.1.0 installed at node_modules\_driver-base@0.1.4
x
C:\Windows\system32>cnpm install macaca-electron -g
Downloading macaca-electron to C:\Users\zhangqiang\AppData\Roaming\npm\node_modules\macaca-electron_tmp
Copying C:\Users\zhangqiang\AppData\Roaming\npm\node_modules\macaca-electron_tmp\_macaca-electron@1.1.6@macaca-electron to C:\Users\zhangqiang\AppData\Roaming\npm\node_modules\macaca-electron
Installing macaca-electron's dependencies to C:\Users\zhangqiang\AppData\Roaming\npm\node_modules\macaca-electron/node_modules
[1/7] co@^4.6.0 installed at node_modules\_co@4.6.0@co
[2/7] webdriver-dfn-error-code@^1.0.3 installed at node_modules\_webdriver-dfn-error-code@1.0.4@webdriver-dfn-error-code
[3/7] driver-base@^0.1.0 installed at node_modules\_driver-base@0.1.4@driver-base
[4/7] xlogger@^1.0.0 installed at node_modules\_xlogger@1.0.6@xlogger
[5/7] selenium-atoms@~1.0.1 installed at node_modules\_selenium-atoms@1.0.2@selenium-atoms
[6/7] electron-prebuilt@^0.37.6 installed at node_modules\_electron-prebuilt@0.37.8@electron-prebuilt
[7/7] macaca-utils@~0.1.8 installed at node_modules\_macaca-utils@0.1.9@macaca-utils
execute post install 1 scripts...
[1/1] scripts.postinstall electron-prebuilt@^0.37.6 run "node install.js"
Downloading electron-v0.37.8-win32-x64.zip
[============================================>] 100.0% of 49.65 MB (4.84 MB/s)
[1/1] scripts.postinstall electron-prebuilt@^0.37.6 finished in 23s
Recently updated (since 2017-06-19): 3 packages (detail see file C:\Users\zhangqiang\AppData\Roaming\npm\node_modules\macaca-electron\node_modules\.recently_updates.txt)
2017-06-23
→ electron-prebuilt@0.37.8 › extract-zip@1.6.5 › concat-stream@1.6.0 › readable-stream@2.3.2 › string_decoder@~1.0.0(1.0.3) (02:36:15)
2017-06-22
→ electron-prebuilt@0.37.8 › extract-zip@1.6.5 › concat-stream@1.6.0 › readable-stream@^2.2.2(2.3.2) (21:48:21)
→ electron-prebuilt@0.37.8 › extract-zip@1.6.5 › concat-stream@1.6.0 › readable-stream@2.3.2 › safe-buffer@~5.1.0(5.1.1) (04:19:28)
All packages installed (166 packages installed from npm registry, used 37s, speed 81.41kB/s, json 183(271.17kB), tarball 2.66MB)
运行
到入到IDEA
问题
找不到 macha 框架
在项目路径里找不到 webdriver-client
macaca run 怎么指定运行哪个测试 js 文件
Error: >> session.js:40:14 [master] pid:19012 Error: Cannot find module 'macaca-android'
at Function.Module._resolveFilename (module.js:536:15)
at Function.Module._load (module.js:466:25)
x
Error: >> session.js:40:14 [master] pid:19012 Error: Cannot find module 'macaca-android'
at Function.Module._resolveFilename (module.js:536:15)
at Function.Module._load (module.js:466:25)
Macaca 等待机制的更多相关文章
- WebDriver元素等待机制
能否构建健壮和可靠的测试是UI自动化测试能否成功的关键因素之一.但实际情况是当一个测试接着一个测试执行的时候,常会遇到各种不同的状况.比如脚本去定位元素或去验证程序的运行状态时,有时会发现找不到元素, ...
- Python+Selenium笔记(十):元素等待机制
(一) 前言 突然的资源受限或网络延迟,可能导致找不到目标元素,这时测试报告会显示测试失败.这时需要一种延时机制,来使脚本的运行速度与程序的响应速度相匹配,WebDriver为这种情况提供了隐式等待 ...
- selenium等待机制
等待机制 因为你要查找的标签由于网速等原因迟迟没有加载出来,你就直接获取这个标签,很明显是报错,现有的简单粗暴的解决办法就是time.sleep(3),睡几秒,也就是设置线程等待,等这个标签加载出 ...
- selenium WebDriverWait类等待机制的实现
在自动化测试脚本的运行过程中,可以通过设置等待的方式来避免由于网络延迟或浏览器卡顿导致的偶然失败,常用的等待方式有三种: 很多人学习python,不知道从何学起.很多人学习python,掌握了基本语法 ...
- selenium等待机制学习笔记
转载至: https://blog.csdn.net/huilan_same/article/details/52544521 1. 强制等待 第一种也是最简单粗暴的一种办法就是强制等待sleep(x ...
- appnium显式等待机制
强制等待: sleep不推荐全局隐式等待 全局隐式等待: 在服务端等待 driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS); ...
- selenium(Java)WebDriverWait等待机制
//标题是不是“百度一下,你就知道” 18 new WebDriverWait(driver,5).until(ExpectedConditions.titleIs("百度一下,你就知道&q ...
- 再谈AbstractQueuedSynchronizer:共享模式与基于Condition的等待/通知机制实现
共享模式acquire实现流程 上文我们讲解了AbstractQueuedSynchronizer独占模式的acquire实现流程,本文趁热打铁继续看一下AbstractQueuedSynchroni ...
- 再谈AbstractQueuedSynchronizer2:共享模式与基于Condition的等待/通知机制实现
共享模式acquire实现流程 上文我们讲解了AbstractQueuedSynchronizer独占模式的acquire实现流程,本文趁热打铁继续看一下AbstractQueuedSynchroni ...
随机推荐
- 'for each' statements are only available if source level is 5.0
在用foreach的时候,出现以下错误: 错误:Syntax error, 'for each' statements are only available if source level is 5. ...
- Matlab神经网络
1. <MATLAB神经网络原理与实例精解> 2. B站:https://search.bilibili.com/all?keyword=matlab&from_source=na ...
- js基础巩固练习
---恢复内容开始--- 今天讲了js的基础知识 js的组成3部分1 ECMAscript 核心 2 DOM 文本对象模型 3BOM 浏览器模型 js 的引入方式三种 1 在body里作为标 ...
- [Selenium With C#基础教程] Lesson-06 单选按钮
作者:Surpassme 来源:http://www.jianshu.com/p/08ee1929875f 声明:本文为原创文章,如需转载请在文章页面明显位置给出原文链接,谢谢. 单选按钮通常用在需要 ...
- Vc6.0 编译发生致命链接错误 :不能打开exe的文件
错误: fatal error LNK1104: cannot open file "Debug/CeshiToolBar1.exe" 解决方法:打开任务管理器,找到对应的exe应 ...
- New Year, New Devs: Sharpen your C# Skills
At the beginning of each new year, many people take on a challenge to learn something new or commit ...
- SqlServer:CTE函数处理递归(WITH语法)
原文地址:http://www.cnblogs.com/xbf321/archive/2009/04/30/1446833.html 我们在做分类处理的时候,总会遇到递归的处理,比如说地区就是一个例子 ...
- asp.net core 2.0类库项目读取配置文件
1.首先在类库项目中添加 这3个库. 2.在类库项目中添加AppSetting.cs.代码如下: using Microsoft.Extensions.Configuration;using Syst ...
- 21天学通C++学习笔记(九):类和对象
1. 类和对象 现实中的人等事物往往具备一些特征并且可以做某些事情,要在程序中模拟这些事物,需要一个结构,将定义其属性(数据)以及其可用这些属性执行的操作(函数)整合在一起.这种结构就是类,而这种结构 ...
- 201621123023《Java程序设计》第7周学习总结
一.本周学习总结 1.1 思维导图:Java图形界面总结 二.书面作业 1. GUI中的事件处理 1.1 写出事件处理模型中最重要的几个关键词. 关键词:事件源.事件监听器.事件处理方法.事件适配器 ...