0

I am writing a scala client that should perform several reads from maven remote repository (dependency tree evaluation).

To perform e2e tests to my code I need a running maven repository (artifactory, nexus, archiva etc...) with several artifacts deployed.

I am looking for a way I can use test utility that will allow me to start embedded server with code configured artifacts and dependency relationship. That way I can set it up just before my test, use it and stop it.

If possible - I want to avoid using filesystem

Of course - that library can be either scala or java

orshachar
  • 4,837
  • 14
  • 45
  • 68
  • 1
    A maven repository is just a bunch of files at specified paths; you don't need a full nexus/whatever if you're just doing reads. – beerbajay Jul 11 '17 at 16:57
  • For maven only you can start Artifactory OSS version and deploy some artifacts, or use it to resolve from Jcenter. – Ariel Jul 17 '17 at 06:15

1 Answers1

0

There is a MockRepositoryServer in the Mojohaus project run by the Maven committers and others that does what you need. It is specifically designed for that exact testing purpose.

You can also use a full blown Nexus Repository Manager in a local install. Either will work.

Manfred Moser
  • 29,539
  • 13
  • 92
  • 123