mirror of
https://github.com/lidarr/lidarr.git
synced 2025-08-21 14:03:29 -07:00
added json.net tests for mono.
This commit is contained in:
parent
86e0d985ef
commit
861c07b2fa
8 changed files with 150 additions and 9 deletions
24
NzbDrone.Libraries.Test/Json/JsonFixture.cs
Normal file
24
NzbDrone.Libraries.Test/Json/JsonFixture.cs
Normal file
|
@ -0,0 +1,24 @@
|
|||
using NUnit.Framework;
|
||||
using Newtonsoft.Json;
|
||||
|
||||
namespace NzbDrone.Libraries.Test.Json
|
||||
{
|
||||
[TestFixture]
|
||||
public class JsonFixture
|
||||
{
|
||||
public class TypeWithNumbers
|
||||
{
|
||||
public int Id { get; set; }
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void should_be_able_to_deserialize_numbers()
|
||||
{
|
||||
var quality = new TypeWithNumbers { Id = 12 };
|
||||
|
||||
var json = JsonConvert.SerializeObject(quality);
|
||||
|
||||
JsonConvert.DeserializeObject(json);
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue