Questions tagged [white-box-testing]

White box testing is a process of giving the input and checking how the given input is been processed to obtain the output from the system.

White box testing

White box testing is a process of giving the input and checking how the given input is been processed to obtain the output from the system. White box testing checks the internal structure of the software. White box testing can be started only after the coding is been completed. Tester who has knowledge of coding performs white box testing. Its advantage is that it checks the internal structure of the system at the basic level and gets it improvised, But the disadvantages is that mostly it does not concentrate on whether the system satisfies users needs or no.

White box test techniques

  1. Statement Coverage
  2. Branch coverage/ Decision Coverage
  3. Path Coverage
  4. Condition Coverage
54 questions
1
vote
1 answer

PowerMockito - Whitebox Get Constructor of inner class with int[] parameter

As the title mentions, I'm using PowerMockito to test a class that contains an inner private class. The inner class has a constructor that has an 'int[]' parameter. Below is the code. final Class clazz = Whitebox.getInnerClassType(SomeClass.class,…
user3050101
  • 51
  • 1
  • 9
1
vote
0 answers

How to suppress parsing, preprocessing of code with the signature "__ASM volatile rbit(x)"

I am unit testing embedded code on a host environment (vectorcast). The code is devloped using an arm-eabi compiler on the target hardware. We are testing it on desktop without any simulator or hardware interface. I am using mingw - 4.5 gcc…
yash
  • 19
  • 2
1
vote
3 answers

should unit tests be black box tests or white box tests?

Say I have three methods, all very similar but with different input types: void printLargestNumber(int a, int b) { ... } void printLargestNumber(double a, double b) { ... } void printLargestNumber(String numberAsString, String numberAsString) { ...…
1
vote
1 answer

Questions on WhiteBox testing, ON-Units, Condition-Coverage

I am reading a book where I am getting stuck at few white box testing concepts. The article in the below link is taken exactly from the book. http://testdesigners.com/testingstyles/ControlFlowTesting.html 1. 'ON-Units' terminology is introduced…
rockbala
  • 2,323
  • 5
  • 20
  • 16
1
vote
2 answers

statement and branch coverage

Hello everyone in these days i am preparing ISTQB exam and i am stuck with one of the questions. mock exam QUESTION 16 Question is ( originally copy paste) here: Given the following code, which is true: IF A > B THEN C = A – B ELSE C = A…
limonik
  • 499
  • 1
  • 6
  • 28
1
vote
1 answer

unit testing Coverage Issue

my ultimate goal is to cover the below code (making complete code green). I am using cantata tool. #define CHECK1 ((a == 1) || (a == 4)) void check_fun(int a, int b) { if((!CHECK1)&&(b>0)&&(b<10)) { …
1
vote
2 answers

Best Practice for Black Box testing

I have a couple of windows service applications that working with sql server. I would like to perform black box testing for my application. I don't want to use unit testing, because I haven't enough time to write test logic for all my methods. I…
Polaris
  • 3,643
  • 10
  • 50
  • 61
0
votes
0 answers

Difference between black box testing, white box testing and grey box testing?

Difference between Black, White and Grey Box Testing? I'm expecting, the relevant and straight answer. I already tried in various ways but i need relevant and straight answer. If anyone answer my question im glad about it and i learn a new thing…
0
votes
0 answers

Select value to test SQL condition

I want to ask about selecting test data for SQL: Assume that I have 4 tables: Books(id, book_name, price, quantity, del_flg) Students(id, student_name, start_date, end_date, del_flg) Borrows(id, student_id, borrow_detail_id,…
0
votes
0 answers

Calculate minimum number of test cases for statement coverage and condition coverage respectively

Could someone draw a flow graph and explain how I get the answer to this question? Question: Calculate the minimum number of test cases for statement coverage and minimum number of test cases for decision coverage respectively. READ A READ B READ…
0
votes
1 answer

Why is white box testing sometimes called glass box testing?

In some references, I have found that white box testing is sometimes called glass box testing. I would like to know what are the reasons behind that.
0
votes
1 answer

Statement Coverage and Decision Coverage - I am not able conclude which is the correct answer.-Need help wrt flow chart

As per my knowledge of Statement coverage and branch coverage Answer should be (a) .But to be very frank still flow chart for this is not clear to me. Can someone pls help me with flow chat.
0
votes
0 answers

How to write test cases using Equivalence Class, Boundary value, and Basis Path Testing

I have a method isPerfect(x) (with 4<=x<=10000) below, how to write test cases based on Equivalence Class, Boundary Value, and Basis Path Testing: public boolean checkPerfectNumber(int x) { if(x >= 4 && x <= 10000) { int sum = 0;…
0
votes
0 answers

I am trying to learn statement coverage analysis

I am trying to learn code coverage analysis; I am bit confused because the following code has loops. Example if the code like this read a; read b; i=0 if a>b while(to i
0
votes
2 answers

White-box test cases with 100% code coverage

I apologize ahead as I'm very new to software testing. But I have what looks like a simple code to create a White-box test cases with 100% code coverage: 01 public class ShapeAreas { 02 03 public double oneParameter(String shape, float x1) 04 { 05 …