• stevecrox@kbin.social
      link
      fedilink
      arrow-up
      2
      ·
      1 year ago

      Maven has unit and integration test phases and there are a multitude of plugins designed to hook into those phases but there are constraints by design.

      Trying to hook everything into the build management system is a source of technical debt, your using a tool for something it wasn’t designed.

      I would look at what makes sense within the build management system and what makes sense in a CI pipeline.

      CI tools have different DSL and usually provide a means to manage environments. Certain integration and system level tests are best performed there.

      For instance I keep system tests as a seperate managed project. The project can be executed from developer machines for local builds but I also create a small build pipeline to build the project, deploy it and run the system tests against it triggered by pull requests.

      This is why I say the build management system doesn’t really change, because you should treat everything as descrete standalone components.

      The Parent POM gets updates once every six months, the basic build verification CI pipeline only changes to the latest language release, etc…

      Projects which try to embed gitflow into a pom or integrate CD into the gradle file are the unbuildable messes I get asked to fix.