







Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Material Type: Exam; Class: Software Testing; Subject: Software Engineering; University: George Mason University; Term: Unknown 1989;
Typology: Exams
1 / 13
This page cannot be seen from the preview
Don't miss anything!








George Mason University Information and Software Engineering
SWE 637 Software Testing and Quality Assurance Y. Wu Fall 2000 Mid Term Exam October 23, 2000
This exam is closed book and notes. Be sure to print your name on the test. Allocate your time according to the points assigned for each question. Please show all work on the test.
You should be able to answer all questions using the pages provided; please answer on this paper if you can. If you do need extra pages, staple them into the exam. If I cannot read your answer, I will mark it wrong.
You have until 6:00pm.
NAME (please print):
1.i. Provide at least four types of testing, which are usually performed during system testing, but not in integration testing.
1.ii. As a manager of a project, what type of role should you acting in terms of testing?
1.iii. Give an example of traditional testing technique that can be applied to the object-oriented software and one is not adequate to test object- oriented software.
(a) Draw the control flow graph for the program JUNK. Draw the graph using the format and definition for basic blocks that we used in class. Annotate the graph edges with the appropriate predicates.
Give minimal test data sets to satisfy the following three criteria for the program JUNK. (A minimal test set that satisfies a criterion is not the smallest possible test set, but a test set such that if we remove any of the test cases then the set will no longer satisfy the criterion. The purpose of asking for a minimal set is so that listing all the tests is NOT a correct answer.) Choose all your test cases from the following set (I will disregard any test cases that do not come from this set): ( 1, 1) (11, -1) (11, 1) (-1, 1) ( 1, -1) ( 0, 0) (-1, -1)
(b) Give a minimal test data set to satisfy the statement coverage criterion.
(c) Give a minimal test data set to satisfy the branch coverage criterion.
(d) Give a minimal test data set to satisfy the MC/DC criterion.
Make each statement below as either True or False and with a short justification. (Justification worth half the credit).
Every test case in T2 must also appear in T3.
T3 satisfies the statement coverage criterion.
T1 satisfies the branch coverage criterion.
If P is incorrect, then T2 reveals any fault in P that T1 reveals.
If P has no loops, then T2 satisfies the all paths criterion.
Make each statement below as either True or False and with a short justification. (Justification worth half the credit).
T1 satisfies the all-uses criterion.
If P has no loops, then T3 satisfies the all-paths criterion.
T3 satisfies the all-defs criterion.
If P is incorrect, then T3 reveals any fault in P that T2 reveals.
Every test case in T2 must also appear in T3.
The procedure will accept three non-negative integer parameters, representing a month, day and year, and return an integer between 1 and 366, indicating the day of the year. If either month, day, or year is invalid (1 ≤ month ≤ 12, 1 ≤ day ≤ month_length, 1990 ≤ year ≤ 1999), the procedure will return 0. (month_length is the number of days in the current month.)
void f(int m, n) { int x,y,t,s,a,i;
x = m + 3 * n; If (m > n) { x = 4 * m; y = 7 * n; } t = x / (y + 14); s = m + n; for(i=s;i<=t;i++) a = i * 4; printf(“a = %d\n”,a); }
For use in question 2:
JUNK (int x,y) { int a, b;
a = 0; if (x > 0) { a = 4; }
if (x <= 10 && y >0) { b = 3 * a; } else { b = 4 * a; } printf(“b = %d\n”, b); }