Software Testing NPTEL Week 9 Assignment

                     

Course Name: Software Testing

Link to Enroll: Click here

These are Answers for Software Testing NPTEL Week 9 Assignment


Q1) How is overloading different from overriding in object oriented programming?
a. Overloading occurs between two methods in the same class and overriding occurs between methods in a class and one of its descendants.
b. Overloading occurs between a method in a class and one of its descendants and overnding occurs between two methods in the same class.

Answer: a. Overloading occurs between two methods in the same class and overriding occurs between methods in a class and one of its descendants.


These are Answers for Software Testing NPTEL Week 9 Assignment


Q2) Which of the following represents use of super() keyword?
a. Sub-classes can explicitly use their parents variables and methods using the keyword super().
b. Sub-classes can use their own variables and methods and not the inherited ones using the keyword super().

Answer: a. Sub-classes can explicitly use their parents variables and methods using the keyword super().


These are Answers for Software Testing NPTEL Week 9 Assignment


Q3) While applying the mutation operator that deletes a method call, how is the value to be returned by the deleted method passed back to the caller method?
a. The method itself is deleted, so the call should also be deleted in the caller method.
b. The value returned by the deleted method is replaced with a suitable statement in the caller.
c. A message is sent to the caller indicating that there is no value to be returned as the method is deleted.
d. The value returned by the deleted method is replaced with a fixed, constant value.

Answer: c. A message is sent to the caller indicating that there is no value to be returned as the method is deleted.


These are Answers for Software Testing NPTEL Week 9 Assignment


Q4) When mutation testing is applied as a black-box testing technique to mutate the inputs, which of the following statement hold true?
a. Both the inputs and the program which is accepting the inputs have to be mutated with one mutation operator.
b. Only the inputs are mutated, the program which is accepting the inputs remains the same.
c. The inputs are not mutated, the program is mutated at a random statement.
d. The inputs are not mutated, the program is mutated at one of the statements that process the inputs.

Answer: c. The inputs are not mutated, the program is mutated at a random statement.


These are Answers for Software Testing NPTEL Week 9 Assignment


Q5) When we change a method call is-divisible(a,b) to is-divisible(b,a) is an example of which of the mutation operators listed below?
a. Integration parameter variable replacement.
b. Integration parameter variable exchange.

Answer: a. Integration parameter variable replacement.


Q6) State yes or no: The programming language Java does not support multiple class inheritance and hence each class only has a single parent.
a. Yes.
b. No.

Answer: a. Yes.


These are Answers for Software Testing NPTEL Week 9 Assignment


Q7) Which of the following integration mutation operator represents changing the order of arguments in method invocations to be the same as that of another overloading method, if one exists?
a. Overloading method change.
b. Argument number change.
c. Argument order change.
d. Reference type change.

Answer: a. Overloading method change.


Q8) State true or false: While testing inputs using mutation testing the inputs always have to adhere to their underlying syntax.
a. True
b. False

Answer: b. False


These are Answers for Software Testing NPTEL Week 9 Assignment


Q9) Towards ensuring that mutation testing subsumes edge coverage, which of the following mutation operators are used?
a. Relational operator replacement.
b. Statement replacement.
c. Logical operator replacement.
d. Condition statement replacement.

Answer: c. Logical operator replacement.


Q10) Which of the statements below are true with reference to mutation testing subsuming all-defs coverage?
a. We need to consider strong mutation to be applied to the statements that contain variable definitions.
b. Both weak and strong mutation on the statements that contain variable definitions will work.

Answer: b. Both weak and strong mutation on the statements that contain variable definitions will work.


These are Answers for Software Testing NPTEL Week 9 Assignment

All weeks Software Testing: https://progies.in/answers/nptel/software-testing

More Solution of NPTEL: https://progies.in/answers/nptel


* The material and content uploaded on this website are for general information and reference purposes only. Please do it by your own first.


These are Answers for Software Testing NPTEL Week 9 Assignment