当前位置:网站首页>Method of designing test cases
Method of designing test cases
2022-07-28 06:54:00 【Xiao Qiao】
Catalog
One 、 Design test cases according to requirements
Two 、 Specific methods of designing test cases
3、 ... and 、 How to evaluate the quality of test cases
One 、 Design test cases according to requirements
Verify the correctness of the requirements .
Analyze requirements , Refine requirements , Extract functional modules from requirements , Divide sub functions , Write test cases according to sub functions .
Two 、 Specific methods of designing test cases
1. Equivalence class
Put the input ( Output is considered only in special cases ) It is divided into several equivalent classes , Select a representative test case from each equivalent class to test , If this test case passes the test , Let's say that the equivalence class represented by this test case passes .
Effective equivalence class : According to the requirement specification , Meaningful input data set , Become a valid equivalence class ;
Invalid equivalence class : Not meeting the requirements ;
In order to solve the problem of too many test cases , Enter situations that cannot be exhausted .
2. The boundary value
Design test cases according to the boundary of input and output .
3. Cause and effect diagram
Cause and effect diagram is a kind of logic diagram ( Identity 、 And 、 or 、 Not ), When there are many inputs , Different combinations of inputs correspond to different outputs , Use cause and effect diagram to analyze the relationship between different input combinations and different outputs .
The steps of designing test cases by causality diagram :
① Analyze all inputs and outputs ;
② Find out the relationship between input and output ;
③ Draw a cause and effect diagram according to the relationship between input and output ;
④ According to the causal picture judgment table ;
⑤ Design test cases according to the decision table .
Cause and effect diagram example :

4. Orthogonal method
An experiment that studies multiple factors and levels ( test ) Method , According to orthogonality , Select the best combination from the input combination for test , The results of the analysis , Analyze the results of this test through the test results obtained from these optimal combinations .
factors : Input variables ;
level : Value of variable ;
Composition of orthogonal table :
① Column : Factor number ( Number of variables )
② Horizontal number : The maximum number of values of each variable
③ That's ok :L=( Horizontal number -1)* Factor number +1
Properties of orthogonal table :
① The number of different data in each column is the same
② The combination of any two columns of different data occurs the same number of times
Orthogonal table design test case steps :
① Identify all inputs ( Variable );
② Determine the number of values of each variable ;
③ Number of determining factors ( Columns of orthogonal table ), Horizontal number ;
④ According to the properties of orthogonal table , Map the values of variables to the table ;
⑤ Write test cases , Each row of the orthogonal table is a test case ;
⑥ Add test cases that are not in the orthogonal table but that you think may appear .
example :
full name 、 mailbox 、 password 、 Confirm the password 、 Verification Code , Only consider filling or not filling .
①②③ Factor number =5; Horizontal number =2; Columns of orthogonal table = Factor number =5; Row of orthogonal table =( Horizontal number -1)* Factor number +1=6
④ Orthogonal table :

⑤ Write test cases according to each line
⑥ Add : Fill in all or nothing .
5. Scene method
Design test cases according to scenario method : Put forward each function point in the scene , Consider the possible different situations of function points , Design test cases according to these situations . for example :ATM ATM .
6. Wrong guess
According to the tester's knowledge , Experience , Intuitively judge which module will have problems , Write test cases specifically for this module , As a supplementary test case method .
3、 ... and 、 How to evaluate the quality of test cases
1. Use cases are clearly expressed , No ambiguity ;
2. The use case has strong operability ;
3. The input and output of use cases are clear , A use case has only one expected result ;
4. The maintainability of use cases is good ;
5. Use cases have high coverage of requirements ;
6. Exposure procedures BUG Your ability is strong .
边栏推荐
- JS四则运算重新封装,解决精度丢失问题
- cocos2d-x 学习笔记——瓦片地图TiledMap
- 修复故障扇区
- How to calculate the size of structure, segment and Consortium (common body)
- Question brushing record ---- reverse the linked list (reverse the whole linked list)
- NAT和PAT的原理及配置
- Personal understanding of Chinese remainder theorem
- [C language] string library function introduction and simulation
- 测试面试题集锦(一)| 软件测试常见必考问题与流程篇(附答案)
- 单项链表的创建、遍历以及按要求查找结点
猜你喜欢

rancher部署实战

Compilation and preprocessing of C language

VMware Workstation 配置net模式

DNS forward resolution experiment

MySQL主从

Technology sharing | detailed explanation of actual combat interface test request methods get, post

Analysis of cyclicbarrier source code of AQS

技术分享 | 接口测试常用代理工具

技术分享 | 接口测试价值与体系

Centos7 deploy MySQL database server
随机推荐
What is a linear table?
Which is the best one to make air conduction headphones? Inventory of the best air conduction headphones
How to simulate the implementation of strcpy library functions
prometheus监控nacos
Array solution script
Question brushing record -- binary tree
On cookies and session
Lancher deployment practice
Technology sharing | send requests using postman
OSI七层模型
Iptables firewall
Array to linked list
设计测试用例的方法
MySQL master master
SSH服务配置
MySQL主从
JS逆向100题——第1题
遍历 二叉树
思寒漫谈测试人职业发展
修复故障扇区