We would probably be able to integrate a TestContainers rule into our various SetupHelpers, making sure that the appropriate containers (database, Elasticsearch, …) are started before tests start. org.hibernate.search.util.impl.integrationtest.common.rule.BackendConfiguration#testRule would be particularly relevant when it comes to Elasticsearch. This would also have the advantage of speeding up the build, as there’s a way to have TestContainers start each container only once for the whole build (using Ryuk). See also this comment: testcontainers could help with dependency upgrades (though no certainty here). There might be a few blockers, mainly support for the databases we need in TestContainers; I know that TestContainers' Elasticsearch support wasn’t compatible with OpenSearch (it rejected any image that’s not the official Elasticsearch one) last time I checked. |