Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

An extension will be executed only if a class marked the corresponding annotation.  For detailed information, please take a look at the tutorial.

  • Test Annotations in Interfaces

Junit5 allows the next annotations in interfaces: 

  1. @Test, @TestFactory, @BeforeEach, @AfterEach can be added to default methods in interfaces
  2. @BeforeAll and @AfterAll can be added to static methods in interfaces
  3. @ExtendsWith and @Tag can be declared on interfaces

And the classes that implement these interface will inherit the test cases.

  • Migration Process.

   Migration from JUnit 4 to 5 is not so difficult, as backward compatibility is available.

...