Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Shared test resources for different projects [duplicate]

I have two projects that need the same test resources. I'm using maven for dependency handling and eclipse for running the tests. How can I share the test resources with maven without cloning them?

like image 262
lilalinux Avatar asked Mar 13 '26 18:03

lilalinux


1 Answers

You could put the test resources in another project or Maven module and add a dependency to this project from the other two (scope test should work). The test resources in the new module/project should go in src/main/resources not in src/test/resources (I think, otherwise they'll be available only during the test goal of this project)

like image 149
Toni Toni Chopper Avatar answered Mar 15 '26 08:03

Toni Toni Chopper



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!