THRIFT-5021 Implement MAX_MESSAGE_SIZE and centralize limits into a TConfiguration class
Client: netstd
Patch: Jens Geyer

This closes #1943
diff --git a/lib/netstd/Tests/Thrift.Tests/Protocols/TJsonProtocolTests.cs b/lib/netstd/Tests/Thrift.Tests/Protocols/TJsonProtocolTests.cs
index 970ce7e..4054a29 100644
--- a/lib/netstd/Tests/Thrift.Tests/Protocols/TJsonProtocolTests.cs
+++ b/lib/netstd/Tests/Thrift.Tests/Protocols/TJsonProtocolTests.cs
@@ -21,7 +21,6 @@
 using System.Threading;
 using System.Threading.Tasks;
 using Microsoft.VisualStudio.TestTools.UnitTesting;
-using NSubstitute;
 using Thrift.Protocol;
 using Thrift.Protocol.Entities;
 using Thrift.Transport;
@@ -36,7 +35,7 @@
         [TestMethod]
         public void TJSONProtocol_Can_Create_Instance_Test()
         {
-            var httpClientTransport = Substitute.For<THttpTransport>(new Uri("http://localhost"), null, null);
+            var httpClientTransport = new THttpTransport( new Uri("http://localhost"), null, null, null);
 
             var result = new TJSONProtocolWrapper(httpClientTransport);
 
@@ -45,7 +44,7 @@
             Assert.IsNotNull(result.WrappedReader);
             Assert.IsNotNull(result.Transport);
             Assert.IsTrue(result.WrappedRecursionDepth == 0);
-            Assert.IsTrue(result.WrappedRecursionLimit == TProtocol.DefaultRecursionDepth);
+            Assert.IsTrue(result.WrappedRecursionLimit == TConfiguration.DEFAULT_RECURSION_DEPTH);
 
             Assert.IsTrue(result.Transport.Equals(httpClientTransport));
             Assert.IsTrue(result.WrappedContext.GetType().Name.Equals("JSONBaseContext", StringComparison.OrdinalIgnoreCase));