I'm trying to write an integration test for an open rasta web service (code bellow)
using(var host = new InMemoryHost(new Configuration()))
{
var request = new InMemoryRequest {Uri = new Uri("http://localhost/foo"), HttpMethod = "GET"};
request.Entity.Headers["Accept"] = "application/json";
var response = host.ProcessRequest(request);
}
But keep getting a 406 response.
If I don't specify the json accept header I get a 500 error.