当前位置:网站首页>Test case writing specification in unittest framework and how to run test cases
Test case writing specification in unittest framework and how to run test cases
2022-07-01 11:12:00 【Field test record】
1、 Writing specifications
1) Test cases need to be written in test start , and test The following characters follow ASCII Code sorting operation
2) Test cases must be written in inheritance unittest.TestCase Class in
2、 Operation mode
1) Use PyCharm Built in unittest function , Unwanted main function
Operation rules :
TestLoader When loading test cases , First, load according to the file path , Find the corresponding module , Then find the corresponding class to run .
2) Use unittest.main function , The operation mode needs to be modified in the upper right corner .
remarks : If you want to modify the prefix of the running case, you can change it in the following way loader.py In file , hold test Change to another string
testMethodPrefix='test'
边栏推荐
- Web foundation of network security note 02
- No statements may be issued when any streaming result sets are open and in use on a given connection
- 8款最佳实践,保护你的 IaC 安全!
- Value 1000 graduation project campus information publishing platform website source code
- node版本管理器nvm安装及切换
- 技术分享 | Linkis参数介绍
- 软件项目管理 9.2.软件项目配置管理过程
- [paper reading] trajectory guided control prediction for end to end autonomous driving: a simple yet strong Ba
- y48.第三章 Kubernetes从入门到精通 -- Pod的状态和探针(二一)
- Spam filtering challenges
猜你喜欢
"Target detection" + "visual understanding" to realize the understanding and translation of the input image (with source code)
Oneconnect plans to be listed in Hong Kong on July 4: a loss of nearly 3 billion in two years, with a market capitalization evaporation of more than 90%
Intel Labs annonce de nouveaux progrès en photonique intégrée
Tianrunyun, invested by Tian Suning, was listed: its market value was 2.2 billion Hong Kong, and its first year profit decreased by 75%
PHP有哪些优势和劣势
CVPR 2022 | Virtual Correspondence: Humans as a Cue for Extreme-View Geometry
The exclusive collection of China lunar exploration project is limited to sale!
我国蜂窝物联网用户已达 15.9 亿,年内有望超越移动电话用户
In June 2022, it was the first programming language?!
Mall applet source code open source version - two open
随机推荐
十年磨一剑:蚂蚁集团可观测性平台 AntMonitor 揭秘
LeetCode 438. Find all letter ectopic words in the string__ sliding window
妙啊!MarkBERT
索引失效的几种情况
Cann operator: using iterators to efficiently realize tensor data cutting and blocking processing
个人商城二开逍遥B2C商城系统源码-可商用版/拼团拼购优惠折扣秒杀源码
node版本管理器nvm安装及切换
2022年6月编程语言排行,第一名居然是它?!
Tempest HDMI leak receive 3
MySQL IN 和 NOT IN () 空列表报错
Exposure:A White-Box Photo Post-Processing Framework阅读札记
How does MySQL copy table data from one database to another (two databases are not linked to the same database)
Mysql的四个隔离级别是如何实现的 (简要)
【MAUI】为 Label、Image 等控件添加点击事件
毕业季·进击的技术er
LeetCode.515. 在每个树行中找最大值___逐一BFS+DFS+按层BFS
选择在中金证券上炒股开户可以吗?安全吗?
TEMPEST HDMI泄漏接收 5
JS日期格式化转换方法
价值1000毕业设计校园信息发布平台网站源码