Hi all! I'm trying to build my first contract but ...
# pact-rust
t
Hi all! I'm trying to build my first contract but have no doubt missed something. Is it possible to use the pact_consumer crate to create a mock_server that has an "application/octet-stream" response with a Bytes body to a request? All of the builder docs seem to require String or json::Value data for the body section, but that ultimately gets converted to Bytes here. Is that TODO on line 90 going to cause me grief, or is there a way around this? I cannot clearly see a way to overload the PactBuilder, InteractionBuilder, ResponseBuilder objects to use pact_models:bodies:OptionalBody directly.
https://docs.pact.io/consumer/contract_tests_not_functional_tests#which-test-is-responsible-for-what Think I'll answer my own question here with the last line of this table in the docs. I shouldn't be using the contract to validate the data being returned.