Esempio n. 1
0
 public void AssertPatched_EquivalentNotStrictNestedArrays_Passes()
 {
     AssertPatched.Equal(
         new[] { new string[] { "Foo" }, new string[] { "Bar" } },
         new[] { new object[] { "Foo" }, new object[] { "Bar" } },
         false);
 }
Esempio n. 2
0
 public void AssertPatched_EquivalentStrictNestedArrays_ThrowsEqualException()
 {
     Assert.Throws <EqualException>(
         delegate()
     {
         AssertPatched.Equal(
             new[] { new string[] { "Foo" }, new string[] { "Bar" } },
             new[] { new object[] { "Foo" }, new object[] { "Bar" } },
             true);
     });
 }
Esempio n. 3
0
        public void AssertPatched_EquivalentNotStrictDictionaries_Passes()
        {
            var x = new Dictionary <string, object>
            {
                { "Key", "Value" }
            };

            dynamic y = new System.Dynamic.ExpandoObject();

            y.Key = "Value";

            AssertPatched.Equal <IDictionary <string, object> >(x, y, false);
        }
Esempio n. 4
0
        public void AssertPatched_EquivalentStrictDictionaries_ThrowsEqualException()
        {
            var x = new Dictionary <string, object>
            {
                { "Key", "Value" }
            };

            dynamic y = new System.Dynamic.ExpandoObject();

            y.Key = "Value";

            Assert.Throws <EqualException>(
                delegate()
            {
                AssertPatched.Equal <IDictionary <string, object> >(x, y, true);
            });
        }
Esempio n. 5
0
 public void AssertPatched_ExactlyEqualNestedArrays_Passes()
 {
     AssertPatched.Equal(
         new[] { new[] { "Foo" }, new[] { "Bar" } },
         new[] { new[] { "Foo" }, new[] { "Bar" } });
 }