Versions Compared

Key

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

...

Pax Exam containers log a warning for each unsupported option type. Make sure to set up logging correctly to avoid missing these warnings. Anchorsharedshared

Shared Default Configuration (since 3.0.0.M1)

To reuse the same configuration for all test classes in a suite and to avoid copying configuration methods, Pax Exam supports a ConfigurationFactory SPI.

If a test class does not have any @Configuration method, Pax Exam loads an implementation of the ConfigurationFactory interface (which must be unique) via the java.util.ServiceLoader and invokes the createConfiguation() method of this factory to obtain the configuration for the current test class.

Thus, to provide a default configuration of your test classes, create a class, e.g. com.example.MyConfigurationFactory, which implements org.ops4j.pax.exam.ConfigurationFactory, and a resource META-INF/services/org.ops4j.pax.exam.ConfigurationFactory containing the fully qualified class name of your configuration factory implementation.

Option Categories

Roughly speaking, options can be categorized into

...