当前位置:网站首页>What is the difference between a white box test and a black box test
What is the difference between a white box test and a black box test
2022-06-24 05:56:00 【Programmers who don't drink Chinese wolfberry】
Zeng Yandao “ A black cat , White cat , As long as you can catch a mouse, you are a good cat ”. The same is true of our tests , Whether it's a black box test or a white box test , As long as it can be tested bug, You can find the problem , Ensuring software quality is a good test method .
For novice software testing Xiaobai , Black box test and white box test are definitely one of the necessary vocabulary . that , What kind of black are they talking about , What's white ? What is the difference between the two ? take it easy , Next, Zhuji Xiaobian will answer your questions and solve your doubts .
The biggest difference between : Focus on different objects
The biggest difference between black box testing and white box testing is that they focus on different objects during testing .
Black box testing is mainly aimed at the functions that show the program to users , White box testing is mainly aimed at the code logic of the program . The former tests the final function , The latter tests the daemon .
Black box testing
Black box , In fact, the literal meaning is to regard the test object as a non open and transparent black box . Black box testing is simply when testing , Regardless of the logical results in the box and the program running , Just check whether the function of the program conforms to its function description according to the requirements specification of the program , Verify that the output is incorrect .

White box testing
It's the opposite of black box , This approach is to think of the test object as an open transparent box . When testing , Testers will take advantage of the internal logic structure of the program and related information , By checking program status at different points , Check whether each path in the procedure can work correctly according to the predetermined requirements .

for instance
If you still don't understand, it doesn't matter , Xiaobian will give you an example to understand . If small A And small B It's a couple of brothers . Small A Going to dinner , But little A You need to work from home , So small A Let small B Go and buy him a suit , It's best to buy it back in two hours .
If in black box mode , Small A( Testers ) Will be small B Make a list of purchases ( So-called : Requirements specifications ), Then tell Xiao B, Now it is 9:45, As long as 11:45 Buy everything before , Just take it home .

If it is under the white box test , The following situations may occur . Small B After reaching the designated shopping mall , Small A Start remote command by phone : First buy a suit , The shop that sells suits , You are going to the designated one . Are you in the south gate now ? If you go to the South Gate , go in , Keep to the right , Go all the way to the inside …… what ? Your north gate ? If it's the North Gate , Once in , Turn left first , Go to the end , To sell drinks , Turn right , Go straight ahead …… Tell the boss to buy a classic black suit , No other colors , The medium price one . Okay , Now go buy a tie . Be sure to watch the color of the tie , Don't spend too much , I want to buy something to match this suit . And match it according to my temperament , Choose a diamond decor , If not, just pure black ……
summary
There are always people who like to compare : Which is better, black box test or white box test ? Actually , It's not hard to see from the example above , The advantages of the two are different . But no matter which test method is used , There's no doubt it's all about finding defects , Discover the risks , To ensure that the software has fewer defects , Better quality . Black box and white box , Always interweave in our testing work .
边栏推荐
- How enterprises overcome the data security barrier with the imminent implementation of the new law | interview with think tank on industrial security concept
- How do users check the domain name registrar? What are the conditions for domain name registration?
- Oceanus practice - develop MySQL CDC to es SQL jobs from 0 to 1
- How to get a secondary domain name? What does a secondary domain name mean?
- How to do domain name resolution? What does domain name resolution mean?
- Tencent Youtu presents a number of AI technologies at the 2021 global digital economy conference
- MySQL series tutorial (I) getting to know MySQL
- The instrument industry builds the supplier SRM mode to manage the development of manufacturers + users
- Progress update | optimization and upgrading of shard nodes
- How to resolve the primary domain name and how to operate it
猜你喜欢
随机推荐
How to buy a website domain name? How to select a website domain name?
Why should the domain name be filed? What materials are needed for the filing of enterprise domain names?
It is necessary to do the industry of waiting insurance evaluation. Let's see if you are on the list
Interpretation of Cocos creator source code: siblingindex and zindex
Risc-v instruction set explanation (7) instruction address alignment and addition and subtraction overflow processing
Idea2020 latest activation tutorial, continuously updated
Material production tool manual
Brief introduction to the working principle of high frequency signal generator
How to resolve the primary domain name and how to operate it
PV and PVC analysis and use in kubernetes
Summary of basic notes of C language (2)
Ups and esxi realize automatic shutdown after power failure
How to build a website with a domain name? Is the website domain name free to use?
Script updates CLB type ingress Certificate in tke cluster
How to register a secondary domain name? What are the precautions when registering?
Kubesphere manages multi tke clusters
How to get a secondary domain name? What does a secondary domain name mean?
Tencent cloud ceontos server patrol script
How to buy a domain name? Do you need to file a domain name purchase?
How to make a website with a domain name? What are the functions of the website?