-Tests
This commit is contained in:
+4
-16
@@ -29,10 +29,12 @@ using System.IO;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using Newtonsoft.Json.Bson;
|
||||
using NUnit.Framework;
|
||||
|
||||
namespace Newtonsoft.Json.Tests.Documentation.Samples.Bson
|
||||
{
|
||||
public class DeserializeFromBsonCollection
|
||||
[TestFixture]
|
||||
public class DeserializeFromBsonCollection : TestFixtureBase
|
||||
{
|
||||
#region Types
|
||||
public class Event
|
||||
@@ -42,23 +44,9 @@ namespace Newtonsoft.Json.Tests.Documentation.Samples.Bson
|
||||
}
|
||||
#endregion
|
||||
|
||||
[Test]
|
||||
public void Example()
|
||||
{
|
||||
//IList<Event> e = new List<Event>
|
||||
// {
|
||||
// new Event {StartDate = new DateTime(2013, 3, 31), Name = "Easter"}
|
||||
// };
|
||||
//MemoryStream ms1 = new MemoryStream();
|
||||
//using (BsonWriter writer = new BsonWriter(ms1))
|
||||
//{
|
||||
// JsonSerializer serializer = new JsonSerializer();
|
||||
|
||||
// serializer.Serialize(writer, e);
|
||||
//}
|
||||
|
||||
//string ss = Convert.ToBase64String(ms1.ToArray());
|
||||
//Console.WriteLine(ss);
|
||||
|
||||
#region Usage
|
||||
string s = "MQAAAAMwACkAAAACTmFtZQAHAAAARWFzdGVyAAlTdGFydERhdGUAgDf0uj0BAAAAAA==";
|
||||
byte[] data = Convert.FromBase64String(s);
|
||||
|
||||
Reference in New Issue
Block a user