public void Does_SendPost_as_POST() { var client = Config.CreateClient(); var request = new SendPost { Id = 1 }; var response = client.Send(request); Assert.That(response.Id, Is.EqualTo(1)); Assert.That(response.RequestMethod, Is.EqualTo(HttpMethods.Post)); Assert.That(response.PathInfo, Is.EqualTo("/json/reply/SendPost")); }
public async Task Does_SendPost_as_POST() { var client = Config.CreateClient(); var request = new SendPost { Id = 1 }; var response = await client.SendAsync(request).ConfigureAwait(false); Assert.That(response.Id, Is.EqualTo(1)); Assert.That(response.RequestMethod, Is.EqualTo(HttpMethods.Post)); Assert.That(response.PathInfo, Is.EqualTo("/json/reply/SendPost")); }