Tagged Tests

Categorize and filter tests using the tagged tests.

We'll cover the following...

JUnit 5 provides the option to filter and categorize tests. We use the @Tag annotation for this.

It is added on top of the class. We can provide a custom value to this annotation.

The following are some syntax rules for tags:

  • A tag must not be null or blank.

  • A ...