wiremock-testcontainers-java icon indicating copy to clipboard operation
wiremock-testcontainers-java copied to clipboard

Support for loading mapping files from 'mappings' folder by default

Open hem-verma opened this issue 1 year ago • 2 comments

Proposal

I propose to add support for loading mapping files from 'mappings' folder by default like It is done for WireMockServer.

When there are multiple tests looking for different mapping file, mappings comes really handy without configuring the WireMockServer. it just works out of the box.

But with WireMockContainer, we have to specify which file to load which adds unnecessary configuration.

References

No response

hem-verma avatar Jun 21 '24 23:06 hem-verma

Yes, it would be a good addition

oleg-nenashev avatar Aug 09 '24 21:08 oleg-nenashev

Hey @oleg-nenashev , I am looking into ways to contribute to the project and I thought I could give this one a try. Could you give me a brief intro on what you would expect from this one if it still desirable?

As suggested, we could load mappings and files from a directory by default (eg: src/test/resources/wiremock/(mappings, __files)). On that same note, would it also make sense to include a new method to change this default path? Similar to what we have on WireMockServer with --root-dir option (eg: .withRootDir() or withRootDirFromResource() ?)

lhcopetti avatar Apr 01 '25 03:04 lhcopetti

Hi, was this ever released?

muppettizer avatar Oct 07 '25 19:10 muppettizer