当前位置:网站首页>What are the benefits of writing unit tests using the unit test framework?
What are the benefits of writing unit tests using the unit test framework?
2022-04-23 01:39:00 【Wei Bo-】
When we write unit tests , Why frame ? How does the unit test framework help developers write 、 Perform the test 、 View results ?
Unit test practice | How does the framework assist |
Easily write structured tests ( The right side of the library provides a framework for developers ) |
Basic classes and interfaces that can be inherited |
Put in code , The attribute used to mark the test method | |
Assertion classes that provide special assertion methods , Used to validate code |
|
Perform one or all unit tests ( The framework provides a test runner , A console or GUI Tools ) |
Discover tests in code |
Run tests automatically | |
Display status during operation | |
You can automate... From the command line | |
View the test run results |
Number of tests run |
Number of tests not run | |
Number of failed tests | |
Failed tests | |
Test failure reason | |
ASSERT news | |
Failed code location | |
It may include the exception stack information that causes the test to fail , You can view various function calls in the call stack based on this |
explain : The unit test code calls the library provided by the unit test framework , Run the test using a stand-alone unit test tool , Developers or an automated compilation process can view the test results .
版权声明
本文为[Wei Bo-]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204230136077703.html
边栏推荐
- GBASE 8s分片表管理操作
- Activity preview | on April 23, a number of wonderful openmldb sharing came, which lived up to the good time of the weekend!
- 轮转法分片
- Solve the problem when installing MySQL
- Itextsharp infrastructure
- 修改数组(并查集)
- ai2022新功能,illustrator 2022 新功能介绍
- 哪些代码需要做单元测试?
- 无关联进程间通信 —— 命名管道的创建和使用
- Gbase 8s Group by 功能介绍
猜你喜欢
W801/W800-wifi-socket开发(一)-UDP
“自虐神器”一夜爆火:用手柄控制自己的脸,代码自取,后果自负
Oracle database query lock table SQL script and delete lock information script (necessary for database development ETL and DBA)
[经验教程]支付宝余额自动转入余额宝怎么设置关闭取消支付宝余额自动转入余额宝?
代码实现发邮件---sendemails
DFS奇偶性剪枝
The most easy to understand service container and scope of dependency injection
什么时候应该编写单元测试?什么是TDD?
Small example of gin - get request 1-handle handles get requests
Self taught programming, don't read theory books foolishly, programmer: it's all left over by others
随机推荐
Introduction to granularity locking of gbase 8s concurrency control
Google developer tool preserve log
计蒜客:等边三角形(DFS)
Gbase 8s客户端与服务器的通信
DFS奇偶性剪枝
Small example of gin - get request 1-handle handles get requests
Modify array (and search set)
王子救公主(DFS)
Activity preview | on April 23, a number of wonderful openmldb sharing came, which lived up to the good time of the weekend!
Gbase 8s存儲結構簡介及空間管理
客户端项目管理经常面临的挑战
In the context of Internet plus, how can enterprises innovate customer service?
Gbase 8s检查点简介
Introduction to gbase8s SQL Engine framework
gin框架的学习--golang
Slow response of analysis API
安装mysql出问题求解决
Leetcode-阶乘函数后 K 个零
engine. Post() handles post requests
Introduction à la structure de stockage de gbase 8S et à la gestion de l'espace