rdf4j
rdf4j copied to clipboard
Clean up test server implementations
The test rig currently has at least four separate implementations of a Jetty-based test server:
- org.eclipse.rdf4j.http.server.TestServer (in rdf4j-http-server unit tests)
- org.eclipse.rdf4j.repository.http.HTTPMemServer (in rdf4j-repository-compliance)
- org.eclipse.rdf4j.query.parser.sparql.SPARQLEmbeddedServer (in rdf4j-sparql-compliance)
- org.eclipse.rdf4j.federated.server.SPARQLEmbeddedServer (in rdf4j-tools-federation)
All four do essentially the same thing: spin up an RDF4J Server on localhost with a few test repositories to run tests over HTTP against. We should unify these into a single reusable test utility.
Seems to be duplicate of #2933
Seems to be duplicate of #2933
Oops! So it is, well spotted. The description on this issue is more up to date so I'll close the other one.
@abrokenjester @barthanssens WDYT about adopting something like https://mjeanroy.dev/junit-servers/ instead of building our own test utility? I did a small POC, and seems to work well.
Here is an MVP POC showing how this could look like: https://github.com/eclipse/rdf4j/pull/4437