-Updated version to 6.0.6
-Fixed WinRT build
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd">
|
||||
<metadata>
|
||||
<id>Newtonsoft.Json</id>
|
||||
<version>6.0.5</version>
|
||||
<version>6.0.6</version>
|
||||
<title>Json.NET</title>
|
||||
<description>Json.NET is a popular high-performance JSON framework for .NET</description>
|
||||
<authors>James Newton-King</authors>
|
||||
|
||||
+2
-2
@@ -1,7 +1,7 @@
|
||||
properties {
|
||||
$zipFileName = "Json60r5.zip"
|
||||
$zipFileName = "Json60r6.zip"
|
||||
$majorVersion = "6.0"
|
||||
$majorWithReleaseVersion = "6.0.5"
|
||||
$majorWithReleaseVersion = "6.0.6"
|
||||
$version = GetVersion $majorWithReleaseVersion
|
||||
$signAssemblies = $false
|
||||
$signKeyPath = "C:\Development\Releases\newtonsoft.snk"
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<OutputPath>bin\Debug\Net45\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
@@ -26,7 +26,7 @@
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<OutputPath>bin\Release\Net45\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
@@ -13,13 +14,19 @@ namespace Newtonsoft.Json.TestConsole
|
||||
public static void Main(string[] args)
|
||||
{
|
||||
Console.WriteLine("Json.NET Test Console");
|
||||
|
||||
string version = FileVersionInfo.GetVersionInfo(typeof (JsonConvert).Assembly.Location).FileVersion;
|
||||
Console.WriteLine("Json.NET Version: " + version);
|
||||
Console.ReadKey();
|
||||
|
||||
Console.WriteLine("Doing stuff...");
|
||||
|
||||
//PerformanceTests t = new PerformanceTests();
|
||||
//t.DeserializeLargeJson();
|
||||
|
||||
WriteLargeJson();
|
||||
//DeserializeLargeJson();
|
||||
//WriteLargeJson();
|
||||
DeserializeJson();
|
||||
|
||||
Console.WriteLine();
|
||||
Console.WriteLine("Finished");
|
||||
@@ -27,6 +34,19 @@ namespace Newtonsoft.Json.TestConsole
|
||||
Console.ReadKey();
|
||||
}
|
||||
|
||||
public static void DeserializeJson()
|
||||
{
|
||||
PerformanceTests t = new PerformanceTests();
|
||||
t.Iterations = 50000;
|
||||
t.Deserialize();
|
||||
}
|
||||
|
||||
public static void DeserializeLargeJson()
|
||||
{
|
||||
PerformanceTests t = new PerformanceTests();
|
||||
t.DeserializeLargeJson();
|
||||
}
|
||||
|
||||
public static void WriteLargeJson()
|
||||
{
|
||||
var json = System.IO.File.ReadAllText("large.json");
|
||||
@@ -35,6 +55,10 @@ namespace Newtonsoft.Json.TestConsole
|
||||
|
||||
Console.WriteLine("Press any key to start serialize");
|
||||
Console.ReadKey();
|
||||
Console.WriteLine("Serializing...");
|
||||
|
||||
Stopwatch sw = new Stopwatch();
|
||||
sw.Start();
|
||||
|
||||
for (int i = 0; i < 100; i++)
|
||||
{
|
||||
@@ -45,6 +69,10 @@ namespace Newtonsoft.Json.TestConsole
|
||||
serializer.Serialize(file, o);
|
||||
}
|
||||
}
|
||||
|
||||
sw.Stop();
|
||||
|
||||
Console.WriteLine("Finished. Total seconds: " + sw.Elapsed.TotalSeconds);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -33,4 +33,4 @@ using System.Runtime.InteropServices;
|
||||
// by using the '*' as shown below:
|
||||
// [assembly: AssemblyVersion("6.0.0.0")]
|
||||
[assembly: AssemblyVersion("6.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("6.0.5.17728")]
|
||||
[assembly: AssemblyFileVersion("6.0.6.17729")]
|
||||
|
||||
@@ -1191,7 +1191,7 @@ namespace Newtonsoft.Json.Tests
|
||||
public Nest A { get; set; }
|
||||
}
|
||||
|
||||
[Test(Description = "Verifies that parameterized JsonConverter constructors are invoked when 'params' are used in JsonConverterAttribute.")]
|
||||
[Test]
|
||||
public void ParametersPassedToJsonConverterConstructor()
|
||||
{
|
||||
ClobberMyProperties clobber = new ClobberMyProperties { One = "Red", Two = "Green", Three = "Yellow", Four = "Black" };
|
||||
@@ -1265,7 +1265,7 @@ namespace Newtonsoft.Json.Tests
|
||||
public string One { get; set; }
|
||||
}
|
||||
|
||||
[Test(Description = "Uses JsonConverter and ItemConverterParameters to demonstrate custom rounding of doubles on a property-by-property basis.")]
|
||||
[Test]
|
||||
public void CustomDoubleRounding()
|
||||
{
|
||||
var measurements = new Measurements
|
||||
|
||||
@@ -370,6 +370,9 @@
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="large.json">
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
</None>
|
||||
<None Include="Newtonsoft.Json.Tests.WinRT_TemporaryKey.pfx" />
|
||||
<Content Include="SpaceShipV2.bson">
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
|
||||
@@ -66,7 +66,7 @@ namespace Newtonsoft.Json.Tests
|
||||
[TestFixture]
|
||||
public class PerformanceTests : TestFixtureBase
|
||||
{
|
||||
private const int Iterations = 100;
|
||||
public int Iterations = 100;
|
||||
//private const int Iterations = 5000;
|
||||
|
||||
#region Data
|
||||
@@ -135,7 +135,7 @@ namespace Newtonsoft.Json.Tests
|
||||
[Test]
|
||||
public void ReadLargeJson()
|
||||
{
|
||||
for (int i = 0; i < 100; i++)
|
||||
for (int i = 0; i < 10; i++)
|
||||
{
|
||||
using (var fs = System.IO.File.OpenText("large.json"))
|
||||
using (JsonTextReader jsonTextReader = new JsonTextReader(fs))
|
||||
@@ -808,6 +808,8 @@ If attributes are not mentioned, default values are used in each case.
|
||||
#region Deserialize
|
||||
public void BenchmarkDeserializeMethod<T>(SerializeMethod method, object json, int? iterations = null, bool warmUp = true)
|
||||
{
|
||||
GC.Collect();
|
||||
|
||||
if (warmUp)
|
||||
Deserialize<T>(method, json);
|
||||
|
||||
|
||||
@@ -74,4 +74,4 @@ using System.Security;
|
||||
// by using the '*' as shown below:
|
||||
|
||||
[assembly: AssemblyVersion("6.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("6.0.5.17728")]
|
||||
[assembly: AssemblyFileVersion("6.0.6.17729")]
|
||||
|
||||
@@ -291,6 +291,7 @@
|
||||
<Compile Include="Utilities\MathUtils.cs" />
|
||||
<Compile Include="Utilities\MethodCall.cs" />
|
||||
<Compile Include="Utilities\MiscellaneousUtils.cs" />
|
||||
<Compile Include="Utilities\PropertyNameTable.cs" />
|
||||
<Compile Include="Utilities\ReflectionDelegateFactory.cs" />
|
||||
<Compile Include="Utilities\ReflectionObject.cs" />
|
||||
<Compile Include="Utilities\ReflectionUtils.cs" />
|
||||
|
||||
@@ -91,5 +91,5 @@ using System.Security;
|
||||
// by using the '*' as shown below:
|
||||
|
||||
[assembly: AssemblyVersion("6.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("6.0.5.17728")]
|
||||
[assembly: AssemblyFileVersion("6.0.6.17729")]
|
||||
[assembly: CLSCompliant(true)]
|
||||
|
||||
Reference in New Issue
Block a user