I asked this same question a little over a year ago on this list when we were at your stage. Before I respond, a bit about my group: We are primarily a Java shop but the group wanted our QA engineers to be able to use Python to automate tests (Python is sometimes recommended for this, since it can be a relatively easy language for non-developers to use quickly and effectively). We needed to write automation tests to exercise our multi-platform ad network - several applications across the network must work in concert to deliver functionality. At the time, the company was new to the idea of B.D.D. (though not T.D.D.) and the Cucumber-JVM project (
https://github.com/cucumber/cucumber-jvm) was not quite ready for prime time. We chose Robot framework for end to end tests but have used Cucumber-JVM for the separate projects. Here are my thoughts after using both in different contexts:
1. Robot Framework seems like it is catered towards testers who have no programming experience. At face value, there are many good libraries (SSHLibrary, Selenium2Library, Database, etc.) that can be utilized to run integration tests without knowing much about programming, as I'm sure you've seen in the examples.
2. Robot Framework outputs decent report documentation, though chasing down failures can sometimes be tricky. Its suite and test level setup and teardown methods are fairly straight-forward.
3. As a developer (and I imagine any QA engineer with decent programming skills), I find writing complex tests to be a chore in Robot. I'm not a fan of its text files, find IDE support to be lacking (w/ the exception of the RIDE framework, which crashed for me enough to abandon it - perhaps it has improved). "For" loops and conditionals are awkward, and finally writing keyword libraries in Robot as text files (and not Python/Java) makes them difficult to use with Python and Java keyword libraries w/o knowing a lot about the framework. For these reasons, I have often questioned the value of Robot Framework (which ends up being a pseudo programming language as soon as any degree of complexity is introduced) over something like nose (
https://nose.readthedocs.org/en/latest/), where I can write simple Python, which will also generate decent reports and allows layered test setups. For this reason, we started bringing most or all of our keywords into Python code exclusively, but then lost the capability to write Gherkin-like Given/When/Then tests (
http://blog.codecentric.de/en/2009/11/givenwhenthen-and-example-tables-using-the-robot-framework/) w/o using .txt files. In Cucumber, this is just an annotation over a Python function. Also, Robot's support for the Gherkin-like syntax is extremely limited; I often hit brick walls. Cucumber's use of regular expressions to translate between a natural language like English and any programming language is key.
4. Cucumber is intended for Acceptance testing only. While the line between high level business acceptance testing and lower level integration testing can be blurred, figuring out how to express lower level integration tests as Cucumber tests is challenging and time-consuming (so sometimes worthwhile, for the same reasons T.D.D. helps developers, by forcing you to think through what you're actually building). Cucumber shines at allowing feature discovery through communication and automated testing of those discovered features into the future. Your tests become documentation at the highest business value. I would argue that it is not the right choice for highly data-driven/bounds testing, as the more you test at this level, the less readable and interesting its resulting documentation will be for your stakeholders and new engineers coming on to a project.
I am working on our automation 2.0 vision at our company, and am hoping to write Python domain classes to encapsulate our business domain (and sub-domains, such as infrastructure), which we can then use in either Robot or nose for our integration tests, and Cucumber-JVM for our higher level acceptance tests.
- 自动化测试框架Cucumber和RobotFramework的实战对比
转自: http://www.infoq.com/cn/articles/cucumber-robotframework-comparison 一.摘要 自动化测试可以快速自动完成大量测试用例,节 ...
- 自动化测试框架Cucumber和Robot Framework的实战对比
自动化测试框架Cucumber和RobotFramework的实战对比 一.摘要 自动化测试可以快速自动完成大量测试用例,节约巨大的人工测试成本:同时它需要拥有专业开发技能的人才能完成开发,且需要大量 ...
- Fitnesse+RestFixture:Web服务回归测试利器
RestFixture是Fitness的一个测试REST服务的插件,用于调用标准的http GET/POST等请求方法,并可以用XPath语法和Javascript语法检验http响应.本文介绍安装运 ...
- Django REST framework 中文教程1:序列化
建立环境 在我们做任何事情之前,我们将使用virtualenv创建一个新的虚拟环境.这将确保我们的包配置与我们正在开展的任何其他项目保持良好的隔离. virtualenv envsource env/ ...
- django-rest-framework之序列化
前言:昨天学习了rest-framework序列化方面的知识,故写了博客记录一下.官网:http://www.django-rest-framework.org/tutorial/1-serializ ...
- drf 教程
1, 序列化 Serialization 创建一个新环境 在做其他事之前,我们会用virtualenv创建一个新的虚拟环境.这将确保我们的包配置与我们正在工作的其他项目完全隔离. virtualenv ...
- API(一)之Serialization
virtualenv is a tool to create isolated Python environments. 建立一个新的环境 Before we do anything else we' ...
- Tutorial 1: Serialization
转载自:http://www.django-rest-framework.org/tutorial/1-serialization/#tutorial-1-serialization Tutorial ...
- django下的framework
可以创建个虚拟环境先,不过我没使用这个方式 virtualenv env source env/bin/activate ------ 退出: To exit the virtualenv envir ...
随机推荐
- Scroller 界面滑动
Scroller 滑动之后滑动器子标签里面的控件,其自身是不动的.这里点在下面的进阶会体现出来. 1. 继承LinearLayout, 相对布局也可以. public class MyLinearL ...
- lg、ln的表示方法
c语言中 函数 log(x) 表示是以e为底的自然对数,即 ln(x) 函数 log10(x) 以10为底的对数,即 lg(x) 以其它数为底的对数用换底公式来表示 log(a)/log(b) 函数 ...
- 兼容IE6\7\8浏览器的html5标签的几个方案
html5大行其道的时代已经到来.如果你还在等待浏览器兼容,说明你已经与web脱节几条街了.当然,这得益于移动客户端的蓬勃发展.如果还在纠结于,是否应该掌握html5和css3技术时,请狠狠的抽自己几 ...
- struts2的动态方法配置
动态方法调用配置 <package name="test" extends="struts-default"> <aciton name=&q ...
- 【转】Java重构-策略模式、状态模式、卫语句
前言 当代码中出现多重if-else语句或者switch语句时.弊端之一:如果这样的代码出现在多处,那么一旦出现需求变更,就需要把所有地方的if-else或者switch代码进行更改,要是遗漏了某一处 ...
- 【贪心】bzoj1572: [Usaco2009 Open]工作安排Job
先是没怎么理解这个贪心……然后贪心又被细节弄挂…… Description Farmer John 有太多的工作要做啊!!!!!!!!为了让农场高效运转,他必须靠他的工作赚钱,每项工作花一个单位时间. ...
- Linux–varnish(一)
简介 Varnish 是一款高性能且开源的反向代理服务器和 HTTP 加速器,其采用全新的软件体系机构,和现在的硬件体系紧密配合,与传统的 squid 相比,varnish 具有性能更高.速度更快.管 ...
- 在centos7中为php7安装redis扩展
在此之前一直是用php5.6,安装redis也没遇到啥问题,嗖嗖的就安装上了 更新php版本到php7后,编译的时候报错 include <ext/standard/php_smart_str. ...
- python+ selenium 实现简历自动刷新
本文用到的文件的下载地址 百度网盘链接: https://pan.baidu.com/s/1wIda-wUz4X_Ck72xgZ6Ddg 提取码: etaa 1 安装Python 和 selenium ...
- 元组-tuple
Python内置的元组数据类型:tuple tuple和list非常类似,但tuple一旦初始化就不能修改,因此它没有append(),insert()这样的方法 当定义一个tuple时,tuple的 ...