-
Notifications
You must be signed in to change notification settings - Fork 3.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
-Added JsonPrimitiveContract and JsonLinqContract
-Removed JsonRaw and replaced with JRaw -Fixed properties on existing derived values not being populated during deserialization
- Loading branch information
Showing
35 changed files
with
835 additions
and
436 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Text; | ||
using NUnit.Framework; | ||
using Newtonsoft.Json.Linq; | ||
|
||
namespace Newtonsoft.Json.Tests.Linq | ||
{ | ||
public class JRawTests : TestFixtureBase | ||
{ | ||
[Test] | ||
public void RawEquals() | ||
{ | ||
JRaw r1 = new JRaw("raw1"); | ||
JRaw r2 = new JRaw("raw1"); | ||
JRaw r3 = new JRaw("raw2"); | ||
|
||
Assert.IsTrue(JToken.DeepEquals(r1, r2)); | ||
Assert.IsFalse(JToken.DeepEquals(r1, r3)); | ||
} | ||
|
||
[Test] | ||
public void RawClone() | ||
{ | ||
JRaw r1 = new JRaw("raw1"); | ||
JToken r2 = r1.CloneToken(); | ||
|
||
Assert.IsInstanceOfType(typeof(JRaw), r2); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.