This exercise helps you to understand how you can write a custom annotation which allows you to add JUnit 5 tags to test classes, nested test classes, and test methods. You can finish this exercise by following these steps:
1. Write a custom annotation which allows you to add the JUnit 5 tag: ‘unitTest’ to test classes, nested test classes, and test methods.
2. Open the
JUnit5TagExerciseTest class that’s found from the
3. Ensure that all test methods found from the
JUnit5TagExerciseTest class have the tag: ‘unitTest’. Use your new custom annotation.
4. Run your tests with Maven or Gradle. Make sure that all three test methods are run.