From 632b55b08f388ecbbd001a411cc8fead77dcef1c Mon Sep 17 00:00:00 2001 From: Simon Fenton Date: Thu, 18 Sep 2014 11:17:17 +1000 Subject: [PATCH] Removed unnecessary stream seek in SetContent - when running on the Microsoft Owin TestServer this was throwing as their resopnse stream is not seekable. --- .../MockHttpService/Nancy/MockProviderAdminRequestHandler.cs | 1 - 1 file changed, 1 deletion(-) diff --git a/PactNet/Mocks/MockHttpService/Nancy/MockProviderAdminRequestHandler.cs b/PactNet/Mocks/MockHttpService/Nancy/MockProviderAdminRequestHandler.cs index 5fa7a718..4e294cbc 100644 --- a/PactNet/Mocks/MockHttpService/Nancy/MockProviderAdminRequestHandler.cs +++ b/PactNet/Mocks/MockHttpService/Nancy/MockProviderAdminRequestHandler.cs @@ -111,7 +111,6 @@ private Response GenerateResponse(HttpStatusCode statusCode, string message) private void SetContent(string content, Stream stream) { var contentBytes = Encoding.UTF8.GetBytes(content); - stream.Position = 0; stream.Write(contentBytes, 0, contentBytes.Length); stream.Flush(); }