public void OptionsRequestToAnyCommandUrl(string url, HttpResponseMessage response) { "When I issue an HTTP OPTIONS request" .When(async () => { response = await Server.CreateRequest(url).SendAsync("OPTIONS"); }); "Then the response should return OK" .Then(() => { response.StatusCode.Should().Be(HttpStatusCode.OK); }); "And the Allow header should be set" .And(() => { response.Content.Headers.Allow.Should().Contain(new[] {"PUT", "OPTIONS"}); }); "And the response body should be empty" .And(() => { response.Body().Should().BeEmpty(); }); }