Why WireMock.net is not compatible with stubs from WireMock.org
See original GitHub issueHi,
We wanted to use stubs generated for WireMock.org (spirng contract testing). It seems that they are incompatible or we are using it in wrong way.
Example from WireMock.net: https://github.com/bredah/csharp-wiremock/blob/master/NetCore.2.2/Mock/__admin/mappings/example.json
Example of stub for WireMock.org:
{
"id" : "f34b38df-059b-401d-a391-2c7e1b21258d",
"request" : {
"url" : "/api/Customers",
"method" : "GET",
"headers" : {
"Content-Type" : {
"equalTo" : "application/json"
}
}
},
"response" : {
"status" : 200,
"body" : "[{\"firstName\":\"Stub1\",\"lastName\":\"Kowalski\"},{\"firstName\":\"Stub2\",\"lastName\":\"Kowalski\"},{\"firstName\":\"Stub3\",\"lastName\":\"Nowak\"},{\"firstName\":\"Stub4\",\"lastName\":\"Nowak\"}]",
"headers" : {
"Content-Type" : "application/json; charset=utf-8"
},
"transformers" : [ "response-template" ]
},
"uuid" : "f34b38df-059b-401d-a391-2c7e1b21258d"
}
Do you have any converter?
Issue Analytics
- State:
- Created 3 years ago
- Comments:12
Top Results From Across the Web
.NET Solutions | WireMock
Compatibility Notice. WireMock.Net is not fully compatible with WireMock in terms of the configuration file formats and Administrative REST API. References:.
Read more >Returning stubbed HTTP responses to specific requests
A core feature of WireMock is the ability to return canned HTTP responses for requests matching criteria. These are described in detail in...
Read more >Proxying and proxy stub mappings
This supports a proxy/intercept setup where requests are by default proxied to another (possibly real, live) service, but where specific stubs are configured ......
Read more >Matching and filtering HTTP requests in WireMock
WireMock supports matching of requests to stubs and verification queries using the following attributes.
Read more >Extending WireMock via custom code
WireMock stub mappings consist in part of a ResponseDefinition . ... Only types compatible with JSON (strings, numbers, booleans, maps and lists) can...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
yes, but decission is really strange. standarization… specially if you were copying idea you could decide to make it compatible… this is json so easy to be compatible
Thank you so much.
Em qui., 16 de set. de 2021 09:37, Stef Heyenrath @.***> escreveu: