1.

When does the wasSuccessful() method of the Runner class return true?(a) The test file compiled(b) The test file ran(c) Some of the test cases ran successfully(d) All the test cases ran succesfullyThe question was posed to me during a job interview.The doubt is from JUnit Test Runners in section Exploring Core JUnit of JUnit

Answer»

Right choice is (d) All the test cases ran succesfully

Easiest explanation: wasSuccesful() METHOD is a public method of the Runner class that RETURNS true if and only if all tests SUCCEEDED.



Discussion

No Comment Found

Related InterviewSolutions