* Fixes of errors detected while integrating DynamORM to existing project

* New features (VirtualColumn, VirtualMode, BeginBlock, EndBlock)
This commit is contained in:
grzegorz.russek
2012-08-12 21:49:48 +00:00
parent 6996111bec
commit bfa078841f
7 changed files with 114 additions and 17 deletions

View File

@@ -26,6 +26,7 @@
* THE POSSIBILITY OF SUCH DAMAGE.
*/
using System.Collections.Generic;
using System.Diagnostics;
using NUnit.Framework;
@@ -53,5 +54,20 @@ namespace DynamORM.Tests.Helpers
Assert.AreEqual(a.GetType(), b.GetType());
}
/// <summary>Test anonymous type value.</summary>
[Test]
public void TestAnonTypeValue()
{
var a = new { x = 1, y = "bla bla" };
var b = new { x = 1, y = "bla bla" };
Assert.AreEqual(a, b);
Assert.IsTrue(a.Equals(b));
Dictionary<object, int> dict = new Dictionary<object, int>() { { a, 999 } };
Assert.IsTrue(dict.ContainsKey(b));
}
}
}