Esempio n. 1
0
        public void IsNull_Fail()
        {
            MockAssertResultHandler mockAssert = new MockAssertResultHandler();

            ServiceLocator.AssertResultHandler = mockAssert;
            ApplicationPathFinder finder = new ApplicationPathFinder("foo");

            MWTAssert.IsNull(finder, "This is a message '{0}'.", "foo");
            UnitTestAssert.AreEqual("This is a message 'foo'.", mockAssert.LastMessage);
        }
Esempio n. 2
0
        public void IsNull_Pass()
        {
            MockAssertResultHandler mockAssert = new MockAssertResultHandler();

            ServiceLocator.AssertResultHandler = mockAssert;
            object o = null;

            MWTAssert.IsNull(o, "Error Message");
            UnitTestAssert.AreEqual("Assert.IsNull", mockAssert.LastMessage);
        }