Theory Question Paper

Practical Question Paper

Sample Paper 1

1.Design the test cases for Boundary Value analysis of the following.

Consider a program that prompts the user to input three numbers (say x, y, z) and the data type for input parameters ensures that these will be integers greater than 0 and less than or equal to 100. The program should then output the numbers in ascending order.

20

2.Design the test cases for Equivalence Partitioning for question 1.

20

3.Viva

5

4.Journal

5

Sample Paper 2

1.Design the test cases for Boundary Value analysis of the following.

Consider a program for determining the largest amongst three numbers. Its input is a triple of integers and the numbers are in [1, 300].

The possible outputs would be largest amongst three numbers or invalid input.

20

2.Design a web page with a two text boxes and two buttons. Write Selenium Script using IDE to enter Username and password and click the submit button. After the submit button is clicked, redirect it to the new page and compare its title. If the title matches, display the message “Title matched” in the output window.

20

3.Viva

5

4.Journal

5

Sample Paper 3

1.Consider a simple program to classify a triangle. Its inputs is a triple of positive integers (say x, y, z) and the datA type for input parameters ensures that these will be integers greater than 0 and less than or equal to 100. The program output may be one of the following words:

[Scalene; Isosceles; Equilateral; Not a triangle] Design the equivalence class test cases.

20

2.Design a web page with a two text boxes and two buttons. Write Selenium Script using IDE to enter Username and password and click the submit button. After the submit button is clicked, redirect it to the new page and compare its title. If the title matches, display the message “Title matched” in the output window.

20

3.Viva

5

4.Journal

5

Sample Paper 4

1.You have got the brilliant idea of setting up a company that sells testing services to software houses. Make a strategic plan for your company, taking into account the following issues:

a. What is the testing process that will be followed in the company?

b. What is the focus of the testing services?

c. What kind of people are you going to hire as staff for the company?

d. How are you going to validate that a testing project carried out in the company has been beneficial to the customer?

e. What kind of automated tools will the company use?

20

2.Design a web page with a two text boxes and two buttons. Write Selenium Script using IDE to enter Username and password and click the submit button. After the submit button is clicked, redirect it to the new page and compare its title. If the title matches, display the message “Title matched” in the output window.

20

3.Viva

5

4.Journal

5

Sample Paper 5

1.The program reads an arbitrary number of temperatures (as integer numbers) within the range -60°C … +60°C and prints their mean value. Design test cases for testing the program with the black-box strategy (Equivalence Partitioning and Boundary value Analysis).

20

2.Design a web page with a two text boxes and two buttons. Write Selenium Script using IDE to enter Username and password and click the submit button. After the submit button is clicked, redirect it to the new page and compare its title. If the title matches, display the message “Title matched” in the output window.

20

3.Viva

5

4.Journal

5

Sample Paper 6

1.When getting a person’s weight and height as input, the program prints the person’s body weight index. The weight is given in kilograms (as a real number, for instance: 82.0) and the height in meters (as a real number, for instance: 1.86). The body weight index equals weight divided by height squared: weight / (height * height). Design test cases for testing the program with the black-box strategy (Equivalence Partitioning and Boundary value Analysis)

20

2.Design a web form using simple HTML. Record a selenium script while filling the form. Run the script. Generate Java Web driver code of the same.

20

3.Viva

5

4.Journal

5

Sample Paper 7

1.An insurance agency has the following norms fixed to provide premium for its policy holders:

a. If age<=25 and no claim has been made, premium increase will be $50, else $25.

b. If age <=25 and number of claims made is one, premium increase will be $100, else $50.

c. If age <=25 and number of claims made is 2-4, premium increase will be $400, else $200.

d. If one or more claims are made, send warning letter. If the number of claims made is 5 or more, cancel policy.

Draw the Decision table and design test cases for Insurance renewal.

40

2.Viva

5

3.Journal

5

Sample Paper 8

1.An insurance agency has the following norms fixed to provide premium for its policy holders:

a. If age<=25 and no claim has been made, premium increase will be $50, else $25.

b. If age <=25 and number of claims made is one, premium increase will be $100, else $50.

c. If age <=25 and number of claims made is 2-4, premium increase will be $400, else $200.

d. If one or more claims are made, send warning letter. If the number of claims made is 5 or more, cancel policy.

Draw the cause effect graph and design the test cases for Insurance renewal.

20

2.Design a web form. Write Selenium IDE test case to open and fill the form.

Generate Java Webdriver code of the script.

20

3.Viva

5

4.Journal

5

Sample Paper 9

1.For the following liability procedure, design test cases using decision/Condition coverage.

Procedure Liability(Age,Gender, Married,Premium)

Begin

Premium:=500;

If(Age<25) and (Gender=Male) and (not Married) Then

Premium=”Premium+1500;”

Else (if (Married or Gender=”Female))” Then Premium=”Premium-200; “

if (Age>45) and (Age<65) Then

Premium=”Premium-100″

End;

20

2.Design a web form. Write Selenium IDE test case to open and fill the form.

Generate Java Webdriver code of the script.

20

3.Viva

5

4.Journal

5

Sample Paper 10

1.Write SRS for developing payroll system. Develop test plan as per IEEE 829 format for the same.

40

2.Viva

5

3.Journal

5

Sample Paper 11

1.Specifications:

The software responds to input requests to change the display mode for a time display device.

The display mode can be set to one of the four values: Two corresponding to displaying either time or date. The other two when altering either time or date.

Four possible input requests:

Change mode (CM) Reset (R) Time Set (TS) Date Set (DS) Change Mode (CM):

Activation of this shall cause the display mode to move between “Display

Time (T)” and “Display Date (D)”Reset (R):

If display mode is set to T or D, then a “reset” shall cause the display mode to be set to “Alter time (AT)” or “Alter Date (AD)” modes.

Time Set (TS):

Activation of this shall cause the display mode to return to T from AT.

Date Set (DS):

Activation of this shall cause the display mode to return to D from AD. Draw the state transition diagram, possible transitions table, State table and write the test cases.

40

2.Viva

5

3.Journal

5

Sample Paper 12

1.For the following program, draw the path coverage diagram, determine cyclomatic complexity write the basis paths to be tested and the test cases.

Euclid(int m, int n) { int r; if (n > m){ r = m; m = n; n = r;

} r = m % n; while( r! = 0){ m = n; n = r; r = m % n;

} return n;

}

20

2.Design a web form using simple HTML. Record a selenium script while filling the form. Run the script. Generate Java Web driver code of the same.

20

3.Viva

5

4.Journal

5

Sample Paper 13

1.void quad_eqn (float A,B,C, Boolean Is_Complex)

{ float Discrim = B*B-4*A*C

float R1,R2;

{

If Discrim<0.0

Is_Complex=true;

Else

Is_Complex=false

Endif;

If not Is_Complex

10 R1=(-B+Sqrt(Discrim))/(2.0*A);

11 R2=(-B-Sqrt(Discrim))/(2.0*A);

12 Endif;

13 End quad_eqn;} 14 }

20

For the above function, draw the following tables and write the test cases: a. Occurrence of variables and their categories.

b. du pairs and their type

c. All c-uses

d. All p-uses

2.Design a web page with a two text boxes and two buttons. Write Selenium Script using IDE to enter Username and password and click the submit button. After the submit button is clicked, redirect it to the new page and compare its title. If the title matches, display the message “Title matched” in the output window.20
3.Viva

5

4.Journal

5

Sample Paper 14

1.Consider the following code:

1. int main (int MaxCols, int Iterations, int

MaxCount)

2. {

3. int count = 0, totals[MaxCols], val = 0;

4. memset (totals, 0, MaxCols * sizeof(int));

5. count = 0;

6. if (MaxCount > Iterations)

7. {

8. while (count < Iterations)

9. {

10. val = abs(rand()) % MaxCols;

11. totals[val] += 1;

12. if (totals[val] > MaxCount)

13. {

14. totals[val] = MaxCount;

15. }

16. count++;

17. }

18. }

19. return (0);

20.}

a. Create a directed control-flow graph for this code.

b. Calculate the cyclomatic complexity.

c. List the basis test paths that should be tested.

20

2.Design a web page with a two text boxes and two buttons. Write Selenium Script using IDE to enter Username and password and click the submit button. After the submit button is clicked, redirect it to the new page and compare its title. If the title matches, display the message “Title matched” in the output window.

20

3.Viva

5

4.Journal

5

Sample Paper 15

1.Design the test cases for Boundary Value analysis of the following.

Consider a program for determining the largest amongst three numbers. Its input is a triple of integers and the numbers are in [1, 300].

The possible outputs would be largest amongst three numbers or invalid input.

20

2.Design an HTML form. Write Selenium webdriver to automate the form filling process.

20

3.Viva

5

4.Journal

5

Sample Paper 16

1.Consider a simple program to classify a triangle. Its inputs is a triple of positive integers (say x, y, z) and the datA type for input parameters ensures that these will be integers greater than 0 and less than or equal to 100. The program output may be one of the following words:

[Scalene; Isosceles; Equilateral; Not a triangle] Design the equivalence class test cases.

20

2.Design a web page with a button. On the click of the button a message box should be displayed with a message. Write a selenium web driver script to capture the test in the message box and display the text in the output window

20

3.Viva

5

4.Journal

5

Sample Paper 17

1.You have got the brilliant idea of setting up a company that sells testing services to software houses. Make a strategic plan for your company, taking into account the following issues:

a. What is the testing process that will be followed in the company?

b. What is the focus of the testing services?

c. What kind of people are you going to hire as staff for the company?

d. How are you going to validate that a testing project carried out in the company has been beneficial to the customer?

e. What kind of automated tools will the company use?

20

2.Design a web page with a button. On the click of the button a message box should be displayed with a message. Write a selenium web driver script to capture the test in the message box and display the text in the output window

20

3.Viva

5

4.Journal

5

Sample Paper 18

1.The program reads an arbitrary number of temperatures (as integer numbers) within the range -60°C … +60°C and prints their mean value. Design test cases for testing the program with the black-box strategy (Equivalence Partitioning and Boundary value Analysis).

20

2.Design an HTML form. Write Selenium webdriver to automate the form filling process.

20

3.Viva

5

4.Journal

5

Sample Paper 19

1.When getting a person’s weight and height as input, the program prints the person’s body weight index. The weight is given in kilograms (as a real number, for instance: 82.0) and the height in meters (as a real number, for instance: 1.86). The body weight index equals weight divided by height squared: weight / (height * height). Design test cases for testing the program with the black-box strategy (Equivalence Partitioning and Boundary value Analysis)

20

2.Design a web page with a button. On the click of the button a message box should be displayed with a message. Write a selenium web driver script to capture the test in the message box and display the text in the output window

20

3.Viva

5

4.Journal

5


Sample Paper 20

1.For the following liability procedure, design test cases using decision/Condition coverage.

Procedure Liability(Age,Gender, Married,Premium)

Begin

Premium:=500;

If(Age<25) and (Gender=Male) and (not Married) Then

Premium=”Premium+1500;”

Else (if (Married or Gender=”Female))” Then Premium=”Premium-200; ” if (Age>45) and (Age<65) Then

Premium=”Premium-100″

End;

20

2.Design a web page with a button. On the click of the button a message box should be displayed with a message. Write a selenium web driver script to capture the test in the message box and display the text in the output window.

20

3.Viva

5

4.Journal

5


Sample Paper 21

1.Consider the program to find the largest amongst three numbers. Find all du paths and identify those du-paths that are definition clear. Also find all du-paths, all uses and all-definitions and generate test cases.

40

2.Viva

5

3.Journal

5

Comment down below if you have any questions and don’t forget share with your classmates.