Starting from:

$25

ECE322-Assignment 4 Solved

1.   The behavior of a communication software system can be represented in the form of the finite state machine shown below. The figure shows the corresponding transition probabilities between the states. 



 

Determine an order in which you would like to test individual states. Which transitions would you like to test first? Justify your answer.

 

              2.  Consider the program P with 6 inputs A, B, C, D, E, F and 3 outputs X, Y, and Z. The input variables assume some values shown in the table below.

 

 



 

 

Page 1  of  2

 

input
values
A
0, 1, 2, 3
B
a, b, c, d, e
C
100, 200
D
7, 8, 9, 10, 11
E
Y, N 
F
,  
 

Consider the input-output testing strategy. Consider the situation when (i) you do not know functional dependencies among the input and output variables, and (ii) where these dependencies are known (as shown in the figure below). 



What is the number of test cases required when using these two strategies. For (ii) propose a collection of test cases. In this strategy, how could you minimize the number of test cases; show an example.

 

3. Given are the following two control flow graphs

 



 

(a)                                             (b)

 

How many test cases do you require to complete branch coverage? How do these numbers compare with the cyclomatic complexity?

 

More products