Annotation Type SmokeTest


  • @Documented
    @Target({METHOD,TYPE})
    @Retention(RUNTIME)
    @Test
    @Tag("smoketest")
    public @interface SmokeTest
    For fast CI build it is helpful to mark important JUnit tests and test method as SmokeTest. If the JUnit tests are started with the system property "patterntesting.runSmokeTest" set then only these marked test classes and methods will be executed. This will help you to start only the important tests for a faster build.

    For finer granularity a level could be set. This level can be set with the same property, e.g. "-Dpatterntesting.runSmokeTest=5". Then only tests with level 5 or less will be executed. The other tests with level 6 or higher will be skipped.

    Note: this feature is reserved for future use. If you would like it raise a feature request.

    Since:
    1.0
    Author:
    oliver
    • Optional Element Summary

      Optional Elements 
      Modifier and Type Optional Element Description
      int level
      You are free to define your only levels here.
      java.lang.String value
      You can change the default string to give a reason why the test will be executed in "SmokeTest mode".
    • Element Detail

      • value

        java.lang.String value
        You can change the default string to give a reason why the test will be executed in "SmokeTest mode".
        Returns:
        the string
        Default:
        "marked as @SmokeTest"
      • level

        int level
        You are free to define your only levels here. Normally "1" is the highest level. You can replace "level" by "priority" if you want - it has the same meaning here. It is not forbidden to define a level "0" or a negative level.
        Returns:
        the int
        Default:
        1