private string SerialisePayload(HttpContent httpContent) { if (httpContent == null) { return(null); } var objectContent = (ObjectContent)httpContent; return(_configuration.JsonSerialiser(objectContent.Content)); }
public void it_should_configure_json_serialiser() { _handlerConfiguration.JsonSerialiser("Test").ShouldBe("\"Test\""); }
private string SerialisePayload(HttpResponseMessage responseMessage) { var objectContent = (ObjectContent)responseMessage.Content; return(_configuration.JsonSerialiser(objectContent.Content)); }
public void it_should_configure_json_serialiser() { _handlerConfiguration.JsonSerialiser(new {}).ShouldBe("{}"); }