예제 #1
0
 public void SameDayAs_OnCommonDojoFoundationDay_WithCommonDojoFoundationDay_ShouldSucceed()
 {
     var dojo = new Dojo(new Ninja(), commonDojoFoundationDay);
     var result = dojo.Evaluate(d => d.Property(x => x.Founded).OnSameDayAs(commonDojoFoundationDay.AddHours(12)));
     Assert.IsTrue(result.succeeded);
     Assert.AreEqual("Dojo: ( )Founded = 11/15/1515 (expected: 11/15/1515)",
                     result.PrintLog());
 }
예제 #2
0
 public void SameDayAs_OnCommonDojoFoundationDay_With200YearsLater_ShouldFail()
 {
     var dojo = new Dojo(new Ninja(), commonDojoFoundationDay);
     var result = dojo.Evaluate(d => d.Property(x => x.Founded).OnSameDayAs(commonDojoFoundationDay.AddYears(200)));
     Assert.IsFalse(result.succeeded);
     Assert.AreEqual("Dojo: (X)Founded = 11/15/1515 (expected: 11/15/1715)",
                     result.PrintLog());
 }