Reference no: EM132847902
ITAP2008 Software Testing - Victorian Institute of Technology
Lab - 1
1. What is software testing?
2. Why do you think software testing is highly important for a software development project?
3. List the steps of Software Testing Life Cycle and write a short description what you would do in each phase.
4. Differentiate the terms bug, fault and failure.
5. Find out a software project which failed due to lack of testing. Write a description about the found project highlighting the details of the project and why and how the project failed due to lack of software testing. (submit output for this question via the Moodle. This worth 2 marks and the marks will be added to your final grade.)
Lab - 2
1. List and describe each stages of the Software Testing Life Cycle (STLC).
2. Software inspections are widely used for verification. What are the benefits of inspection? What kinds of errors will inspection catch that testing cannot?
3. Some companies exclude all management from code inspections. What are the advantages and disadvantages of this rule?
4. Briefly describe each of the following approaches for structuring an inspection meeting. What are the advantages of each?
i. Using a checklist
ii. Conducting a walkthrough
5. What factors reduce the effectiveness of inspections? What can be done to address these problems?
6. Explain the role of the Moderator in an inspection team.
7. Imagine you work for an aerospace company that used to carry out Fagan inspections of program code, but which now uses an automatic code generation tool that generates programs from design notations. The output of the tool is hard to understand as it is not commented, and is poorly structured. For this reason, the company has cancelled all code inspections and plans to rely on testing as its main verification technique. What are the advantages and disadvantages of this decision?
Lab - 3
1. Explain what is statement, decision and condition coverage.
2. Use following test cases and Identify the paths that could be tested in the program segment indicated in the Figure 1.
a. A1=2, B=0, X=4
b. A=2, B=1, X=1
c. A=1, B=0, X=2
d. A=1, B=1, X=1

Figure 1. Flowchart for a simple program with multiple conditions
3. Use following scenario and derive equivalence classes for testing. And create a table that shows test case number, test data, expected outcome and class covered.
Grocery Store
Consider a software module that is intended to accept the name of a grocery item and a list of the different sizes the item comes in, specified in ounces. The specifications state that the item name is to be alphabetic characters 2 to 15 characters in length. Each size may be a value in the range of 1 to 48, whole numbers only. The sizes are to be entered in ascending order (smaller sizes first). A maximum of five sizes may be entered for each item. The item name is to be entered first, followed by a comma, then followed by a list of sizes. A comma will be used to separate each size. Spaces (blanks) are to be ignored anywhere in the input.
4. Case Study - MTEST Multiple choice study program
MTEST is a program that grades multiple-choice examinations. The input is a data file named OCR, with multiple records that are 80 characters long. Per the file specification, the first record is a title used as a title on each output report. The next set of records
describes the correct answers on the exam. These records contain a ‘‘2'' as the last character in column 80. In the first record of this set, the number of questions is listed in columns 1-3 (a value of 1-999). Columns 10-59 contain the correct answers for questions 1-50 (any character is valid as an answer). Subsequent records contain, in columns 10-59, the correct answers for questions 51-100, 101-150, and so on.
The third set of records describes the answers of each student; each of these records contains a ‘‘3'' in column 80. For each student, the first record contains the student's name or number in columns 1- 9 (any characters); columns 10-59 contain the student's answers for questions 1-50. If the test has more than 50 questions, subsequent records for the student contain answers 51-100, 101-150, and so on, in columns 10-59. The maximum number of students is 200. The input data are illustrated in Figure 4.4. The four output records are:
1. A report, sorted by student identifier, showing each student's grade (percentage of
answers correct) and rank.
2. A similar report, but sorted by grade.
3. A report indicating the mean, median, and standard deviation of the grades.
4. A report, ordered by question number, showing the percent- age of students answering each question correctly.
Questions
1. Identify test cases
2. Identify boundary value cases related to the student's answers
3. Identify some error guessing test cases for the program.
Lab - 4
Review Questions
1. What is unit testing?
2. What is a test case?
3. Explain what are test driver and test stub and why it is required?
4. Explain non-increment and increment testing.
5. What is top-down and bottom-up testing?
Practice Questions
1. Unit testing is the process of testing a single program unit (e.g. a procedure) in isolation from the rest of the program. How would you go about choosing test cases for unit testing?
2. Boeing estimates that half the cost of the software development for the 777 aircraft was
spent on testing, including regression testing. How might this cost be reduced without sacrificing quality?