#request-response-samples
This directory contains request / response samples. This is the fastest way to add tests, and it allows us to focus on higher level interfaces that should never change. We can change the guts of node-soap with more confidence as more samples are added herein.
Follow this process to add samples:
- Create a directory that combines the client method to invoke along with the
test case name i.e.
Operation__make_sure_short_is_returned_as_number
. This would invokeclient.Operation
under a"make sure short is returned as number"
test case. - Add the following files within the directory just created:
request.json
- This is the data fed to the client method being invokedrequest.xml
- This is the expected XML that should be sent to the serverresponse.xml
- This is the XMl that the server responds withresponse.json
- This is the expected JSON from parsing the response XMLerror_response.json
- This is the expected JSON root attached to the error object when a fault occurssoap.wsdl
- This is the WSDL that defines the operation and messageswsdl_options.json
- This is the wsdl options to create request. (ignorenamespacers, ignoredbasednamespaces).