-
Notifications
You must be signed in to change notification settings - Fork 27
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Stubs loaded from absolute path #60
Comments
You can use the So in your case you could use.
|
Thanks for your response. We actually tried using what you propose, and it doesn't seem to work. We're getting this error:
It looks like Wiremock is trying to load our response body file as a stub mapping using the JSON API when in reality we're using |
Does the folder contain stub files and response/request body files? It looks like WireMock is parsing a body file as a stub file and fails deserializing it. In all the cases I tested the body was part of the stub file (inline body). Can you share a sample project to share so I could have a closer look myself? When recording stub with external body files I have seen that WireMock stores the stubs in a So you could try to have
Then use
|
We're trying to integrate wiremock-spring-boot-starter in our project using the default configuration (adding dependency +
@WireMockTest
). We have our response body files undersrc/test/resources/__files
, which is the default location for Wiremock. When we run our tests we get this exception:It looks like Wiremock is trying to find the files using an absolute path, instead of going to the classpath. In fact, if we create a
__files
in the root directory of our computer with the same contents the tests work fine.We haven't been able to figure out how to configure this properly to load the contents from the classpath, is there any way to do it?
The text was updated successfully, but these errors were encountered: