public void Test_NotNull() { NotNullSpecification s = new NotNullSpecification(); Assert.IsTrue(s.Test(new object()).Success); Assert.IsFalse(s.Test(null).Success); Assert.IsFalse(s.Test("").Success); // treat empty string as null Assert.IsTrue(s.Test(0).Success); }