Page 66 - SOFTWARE TESTING & QUALITY ASSURANCE
P. 66

Unit 4: White Box Testing



                          class TestProg {
                          public static void main(String[ ] args)
                         {

                          int mark = 76;
                          char grade;

                           if (mark >= 90) {
                           grade = 'A'
                           } else if (mark >= 80) {
                             grade = 'B';
                           } else if (mark >= 70) {
                             grade = 'C'
                           } else if (mark >= 60)
                             grade = 'D';
                           } else {
                             grade = 'F';
                           }
                           System.println("Your Grade is:" + grade);
                          }
                         }
               Answers: Self Assessment

                1.   (a) True                          (b) False
                          (c) True                          (d) True

                          (e) True                         (f) True

                          (g) True                       (h) True

                2.   (a) Hacker’s                                  (b) Regular software failures
                     (c) Formal Reviews, Coding standards and guidelines, Code review
                     (d) Second                                    (e)Users, testers                                        (f) Instructions

                3.   (a) Open box testing

                          (b)  Formal review

                          (c)  Reliability
                          (d) Improper declaration  of variables and constants

                          (e)  Data coverage testing

                          (f) Bottom-Up testing

















                                        LOVELY PROFESSIONAL UNIVERSITY                           59
   61   62   63   64   65   66   67   68   69   70   71