On 14. Sep 2025, at 18:11, Elliotte Rusty Harold <[email protected]> wrote: > > On Sun, Sep 14, 2025 at 1:10 PM Rüdiger <[email protected]> wrote: >> >> On 14. Sep 2025, at 12:32, Elliotte Rusty Harold <[email protected]> wrote: >>> In general ITs, including our own, are too flaky, too heavyweight, and >>> too configuration dependent to execute them by default when the user >>> is trying to do something else like package or install. >> >> `verify` is _after_ the `package` phase, so that is not an issue. >> >> And most often, `install` is not what you want anyway. Prefer `package` then. >> >> If your ITs are flaky, heavy, etc., maybe you should fix them? >> But if that is a deliberate choice, just set `-DskipITs`. > > That's essentially proposing to convert all ITs to unit tests, in > which case we don't need failsafe at all. The reason we separate ITs > from unit tests is that some operations like bringing up and > communicating with an actual database are fundamentally stochastic, > unreliable, and slow.
Normally, unit tests run in the `test` phase, while ITs run in the `verify` phase. If you just want to package your artifact: `mvn package`... includes unit test. If you want to run your ITs: `mvn verify`... includes unit and ITs. If you have ITs, but don't want to run them (e.g. locally), just add `-DskipITs`. And you can add that to the properties in the pom. --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
