当前位置:网站首页>Do you know the advantages and disadvantages of several open source automated testing frameworks?
Do you know the advantages and disadvantages of several open source automated testing frameworks?
2022-07-06 15:13:00 【Test Xiaowan】
Catalog
1. Robot Framework
Robot Framework(RF) Is used for acceptance testing and acceptance test driven development (ATDD) Automatic testing framework of . be based on Python To write , But it can also be in Jython(Java) and IronPython(.NET) Up operation , Provide cross platform support (Windows、Linux or MacOS ).
advantage :
- By using keywords to drive tests (KDT) The method simplifies the automatic testing process , Easy for testers to create readable tests .
- The test data syntax is simple and easy to use .
- The ecosystem is rich . It consists of various general test libraries and tools , These tools were developed as independent projects .
- Highly scalable .
- It can be done by pabot or Selenium Grid Execute parallel tests .
shortcoming :
- Customize HTML The report is troublesome .
If it is for a wide range of libraries and extensions KDT automated testing , It is recommended to use this cross platform framework . If you want to add new keywords ( adopt RF Test library API ), Need to have Java / Python / C Basic knowledge of language .
2. JUnit
JUnit It's about Java Unit test framework of application , For writing and running repeatable tests .
advantage :
- pure Java To write .
- Support Test Driven Development (TDD).
- Allow to create your own unit test case suite .
- Can work well with other tools ( Such as Maven ) and IDE( Such as IntelliJ ) Integrate .
- Long term development , It has its own huge user group , Documents can be easily found .
shortcoming :
- if necessary mocking Ability , Additional Mockito( Or other simulation libraries ).
- because JUnit Method names in are affected by Java Agreed restrictions and other reasons , It is difficult for non-technical personnel to understand the test results .
If you are working for your Java Application writing unit tests , Then this may be the best choice . however , For functional testing or non Java application , Other solutions should be considered .
3. Spock
Spock Is used for Java and Groovy Applied testing and specification framework , be based on JUnit .
advantage :
- The test is readable , Support simple English sentences , Easy to read .
- Provide surrounding context , Thus, it is easy to understand how to solve the fault .
- built-in mocking and stubbing function .
- Support data-driven testing (DDT).
shortcoming :
- You need to have basic Groovy language knowledge .
If your application is based on JVM Of , And the goal is to use DSL Conduct BDD automated testing , Then this framework is suitable for !
4. NUnit
NUnit It supports all .Net The language's unit testing framework . It was originally based on Junit Inspired by the , Full adoption C# To write , It has been completely redesigned to use more .NET Language function .
advantage :
- Fast startup and test execution .
- With assertions and comments .
- Support for parallel testing .
- Support Test Driven Development (TDD).
shortcoming :
- Non cross platform , Only applicable to .Net Language .
- Not integrated into Visual Studio echo In the system , It means that using it requires more maintenance .
A good one C# Open source unit testing framework , Has a long history , High reputation . however , If you are ready to use .NET Language , You can also consider MSTest .
5. TestNG
TestNG It's a Java Automated testing framework , suffer JUnit and NUnit Inspired by the , But some functions have been improved and added . Designed to cover all automated test categories : unit testing 、 A functional test 、 End to end 、 Integration testing, etc .
advantage :
- Easy to integrate into maven In circulation .
- Enable developers to write flexible and powerful tests .
- Support data-driven testing (DDT).
- Notes are easy to understand .
- Test cases can be easily grouped .
- Allow the creation of parallel tests .
shortcoming :
- Only support Java , At least you need to have Java Basic knowledge of programming language .
- Time must be invested in framework setting and design .
If you use Java , And is looking for an end-to-end automated testing framework , At the same time, I am willing to invest a little time in setting the framework , You should consider using TestNG .
6. Jasmin
Jasmine It's a JavaScript Unit test framework , Also known as JavaScript Behavior driven development (BDD) The test framework . For web pages 、Node.js Project or anything that can run JavaScript The place of . It is mainly related to AngularJS Pairs using .
advantage :
- except JavaScript , It can also run in Python and Ruby in . If you want to run client tests on your server , It can help you .
- By many CIs Use and support .
- Built in syntax for assertions .
shortcoming :
- Most of the time , It requires a test runner ( Such as Karma ).
- Difficult to test asynchronously .
If you are looking for a unified ( client - The server ) Unit testing solutions ,Jasmin May be very suitable .
7. Mocha
Mocha It's a JavaScript Unit test framework , It's in NodeJs Run tests on , Mainly with ReactJS Pairs using .
advantage :
- Built in test runner .
- Support asynchronous testing .
- Flexible use , You can use any assertion library that meets your needs (Chai、expect.js、Must.js etc. ) As Node standard “ Assertion ” A functional alternative .
shortcoming :
- Relatively new ( From 2012 year ), It means that there are many unknowns and variability , In some aspects, it may lack user base and support .
Only basic test structures are provided , Therefore, additional settings and configurations are required ( It may be beneficial for some ).
If you're looking for JavaScript Independent unit testing framework ,Mocha First choice !
Thank everyone who reads my article carefully !!!
If you can use the following information, you can take it away directly :
1、 Self study development or test the necessary complete project source code and environment
2、 Test all templates in the work ( test plan 、 The test case 、 Test report, etc )
3、 Classic interview questions for software testing
4、Python/Java Automation test practice .pdf
5、Jmeter/postman Interface test full set of video acquisition
I personally sorted out some technical materials I have sorted out in my software testing career in recent years , contain : e-book , Resume module , Various work templates , Interview treasure , Self study projects, etc . Please find me in the comment area if you need it. Thank you .
边栏推荐
- Build your own application based on Google's open source tensorflow object detection API video object recognition system (II)
- Statistics 8th Edition Jia Junping Chapter 4 Summary and after class exercise answers
- The salary of testers is polarized. How to become an automated test with a monthly salary of 20K?
- Global and Chinese markets for GaN on diamond semiconductor substrates 2022-2028: Research Report on technology, participants, trends, market size and share
- ucore lab1 系统软件启动过程 实验报告
- Differences between select, poll and epoll in i/o multiplexing
- Global and Chinese market of RF shielding room 2022-2028: Research Report on technology, participants, trends, market size and share
- Threads and thread pools
- Rearrange spaces between words in leetcode simple questions
- DVWA exercise 05 file upload file upload
猜你喜欢

全网最详细的postman接口测试教程,一篇文章满足你

CSAPP homework answers chapter 789

How to transform functional testing into automated testing?
自动化测试你必须要弄懂的问题,精品总结

The minimum sum of the last four digits of the split digit of leetcode simple problem

ucore lab1 系统软件启动过程 实验报告

UCORE lab2 physical memory management experiment report

Stc-b learning board buzzer plays music

China's county life record: go upstairs to the Internet, go downstairs' code the Great Wall '

Build your own application based on Google's open source tensorflow object detection API video object recognition system (II)
随机推荐
Express
How to transform functional testing into automated testing?
Example 071 simulates a vending machine, designs a program of the vending machine, runs the program, prompts the user, enters the options to be selected, and prompts the selected content after the use
Knowledge that you need to know when changing to software testing
C language do while loop classic Level 2 questions
Sleep quality today 81 points
How to rename multiple folders and add unified new content to folder names
[oiclass] maximum formula
Zhejiang University Edition "C language programming experiment and exercise guide (3rd Edition)" topic set
Global and Chinese markets of cobalt 2022-2028: Research Report on technology, participants, trends, market size and share
Contest3145 - the 37th game of 2021 freshman individual training match_ A: Prizes
Global and Chinese markets for GaN on diamond semiconductor substrates 2022-2028: Research Report on technology, participants, trends, market size and share
Cadence physical library lef file syntax learning [continuous update]
自动化测试中敏捷测试怎么做?
Programmers, how to avoid invalid meetings?
What is the transaction of MySQL? What is dirty reading and what is unreal reading? Not repeatable?
[issue 18] share a Netease go experience
Opencv recognition of face in image
Mysql database (V) views, stored procedures and triggers
基于485总线的评分系统双机实验报告