1.

Explain the execution procedure of the JUnit test API methods?

Answer»

Following is how the JUnit execution procedure works −

  • First of all method annotated as BeforeClass execute only once.

  • Lastly, the method annotated as AfterClass executes only once.

  • Method annotated as Before executes for each test case but before executing the test case.

  • Method annotated as After executes for each test case but after the execution of test case.

  • In between method annotated as Before and method annotated as After each test case executes.



Discussion

No Comment Found