Question concerning httpPayload
and empty input/outputs in RestJson1 protocol tests
#1068
Labels
documentation
This is a problem with documentation.
guidance
Question that needs advice or information.
Consider this protocol test:
Where the operation's input is:
If the server receives the HTTP request defined in the test case, I would expect it to be deserialized to the following Rust struct:
We still received a JSON body
{}
, sopayload_config
which is bound to the HTTP body viahttpPayload
, should beSome
. However, the JSON object contains no fields, sodata
isNone
.However, the test expects:
because its
params
attribute does not specify a value for thePayloadConfig
field.Is the test definition correct?
I think that this is at odds with another test in the test suite. According to this other protocol test:
, server implementations should always respond with a JSON object, even if the output parameters are empty. So how do you distinguish between the above two cases if a
TestPayloadStructureOutput
defined like above had aPayloadConfig
bound to the body withhttpPayload
?The text was updated successfully, but these errors were encountered: