From 9b5a482b8d2ca73dadcbf06526960689abca4891 Mon Sep 17 00:00:00 2001 From: Stef Heyenrath Date: Thu, 8 Mar 2018 11:00:19 +0100 Subject: [PATCH] Also handle application/x-www-form-urlencoded as string body --- src/WireMock.Net/Util/BodyParser.cs | 8 +++++++- src/WireMock.Net/WireMock.Net.csproj | 2 +- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/WireMock.Net/Util/BodyParser.cs b/src/WireMock.Net/Util/BodyParser.cs index 51a31533..617dbff2 100644 --- a/src/WireMock.Net/Util/BodyParser.cs +++ b/src/WireMock.Net/Util/BodyParser.cs @@ -10,7 +10,13 @@ namespace WireMock.Util { internal static class BodyParser { - private static readonly string[] TextContentTypes = { "text/", "application/xml", "application/javascript", "application/typescript", "application/xhtml+xml" }; + private static readonly string[] TextContentTypes = + { + "text/", + "application/javascript", "application/typescript", + "application/xml", "application/xhtml+xml", + "application/x-www-form-urlencoded" + }; private static async Task> ReadStringAsync(Stream stream) { diff --git a/src/WireMock.Net/WireMock.Net.csproj b/src/WireMock.Net/WireMock.Net.csproj index e516c50f..00d661c2 100644 --- a/src/WireMock.Net/WireMock.Net.csproj +++ b/src/WireMock.Net/WireMock.Net.csproj @@ -3,7 +3,7 @@ Lightweight Http Mocking Server for .Net, inspired by WireMock from the Java landscape. WireMock.Net - 1.0.3.4 + 1.0.3.5 Alexandre Victoor;Stef Heyenrath net452;net46;netstandard1.3;netstandard2.0 true