White box Testing interview question and Answers

White box Testing interview question and Answers

ANS: White box testing (WBT) is also called Structural or Glass box testing.

White box testing involves looking at the structure of the code.

White box testing is a method to test the functionality of the code by passing parameters within the code itself.

When you know the internal structure of a product, tests can be conducted to ensure that the internal operations performed according to the specification. And all internal components have been adequately exercised.

2. What are the other names of Whitebox Testing? Why?

ANS : Clear Box Testing
Glass Box Testing
Transparent Box Testing
Translucent Box Testing or Structural Testing

White Box testing uses internal perspective of the system to design test case based on internal structure. It is called clear box testing because it allows the developer to peek inside the box and focus on using internal knowledge of the software to guide the selection of test data. The code is considered as big glass box or clear box by developer who can see inside the box.

3. Why we do White Box Testing?

ANS: To ensure:

That all independent paths within a module have been exercised at least once.
All logical decisions verified on their true and false values.
All loops executed at their boundaries and within their operational bounds internal data structures validity.

4. What is the need of White Box Testing?

ANS: To discover the following types of bugs:

Logical error tend to creep into our work when we design and implement functions, conditions or controls that are out of the program.

The design errors due to difference between logical flow of the program and the actual implementation.

Typographical errors and syntax checking.

5. What is merits and demerits of White box and Black box testing?

ANS: White box and Black box testing both are dynamic testing techniques.

White box testing: testing based on the paths and internal structure and implementation of the software under test. Here we r checking the code by some coverage processes.

Black box testing: testing based on the behavior and functionality of the software. this is also called as functional testing.

6. What is Data flow testing present in whitebox testing?

ANS: Data flow testing is a White-box test design technique. The testing is based on selecting paths through the programs control flow in order to find the sequence of events related to the status of data objects. It uses control graph to find the anomalies.

7. What are the limitations of white box testing?

ANS: White box testing is to analysis the internal structure of program code.

It is not possible for testing each and every path of the loops in program. This means exhaustive testing is impossible for large systems. This does not mean that white box testing is not effective. By selecting important logical paths and data structure for testing is practically possible and effective.

8. What are prerequisites for white box testing?

ANS: In general prerequisites for white box testing are the same as for black box testing. The only difference is the access to the application source code. The white box tester should ask for detailed requirement, functional specifications, high-level design documents, detailed design documents and source code. The white box QA Engineer would analyze the source code and prepare test cases for testing the functionality to ensure that the code is behaving according with the requirements and specifications.

9. How is Whitebox testing used with Integration testing?

ANS: Integration testing looks at how all components of an application interact. White box integration tests specifically look at the interfaces between the components.

10. Who will do white box testing only developers /testers also ?

ANS: White Box testing is done by both developers and tester. In case of projects (eg: Railways, aeronautics) there are standards (eg CENELAC) to be which demands testing to be done by a tester in such cases the white box testing is done by tester and not developer. The tester will have a knowledge of the coding language only then is he called a white box tester The tester does the white box testing using rational tools like Rational Test Real Time (RTRT).

11. What are the analysis a tester should perform before carrying out whitebox testing?

ANS: White box testing provides the testers with complete knowledge of the infrastructure to be tested, often including network diagrams, source code, and IP addressing information.

It can be performed to validate whether code implementation follows intended design, to validate implemented security functionality, and to uncover exploitable vulnerabilities.

12. What is Equivalence partitioning (EP) and boundary value analysis (BVA) in whitebox testing?

ANS: Equivalence partitioning: A test strategy used for black box and white box, in which we categorize inputs into several equivalent sets and pick at least one from each such set. The point here is while categorizing the sets we have to do it in such a way that the entire set behaves in the same way.

Boundary value analysis (BVA): Another strategy used for both BB and WB, in which we fosus on testing the functionality or chunk of code when dealing with boundary values.

13. What are all the tools available for white box testing?

ANS: Source Code Analyzers, Debugger and Fault Injectors.

14. Why does a user perform Whitebox testing, when Black box testing is available?

ANS: When u perform white box testing we are giveing input data and validating the out put results we know that what exactly the code is doing

In black box testing we validate the just output results we don’t what is the code is doing

White Box testing tests the unit of code / program where as Black Box testing has nothing to do with the internal code all it does is based upon expected output it test the system.

15. What is meant by API Testing? Explain the API Testing process?

ANS: API testing is to make sure that the basic units of the software application function perfectly well.

We perform API testing right from the initial stages of the product cycle to the final phase, ensuring that the product release in the market is error-free and worth every penny you invested. API testing process involves testing the methods of NET, JAVA, J2EE APIs for any valid, invalid, and inopportune inputs, plus testing the APIs on Application servers.

16. What is cyclomatic complexity?

ANS: Cyclomatic complexity is the most widely used member of a class of static software metrics. The cyclomatic complexity of a software module is calculated from a connected graph of the module.

For Testing Tools Online Training please visit http://www.revanthtechnologies.com