public override void TestInitialize()
        {
            DateTime now = DateTime.Now;

            InitSubjects();
            AbstractBeginEndTimeInterval subject = new BeginEndTimeInterval(now, null);
            AddSubject(subject);
            subject = new BeginEndTimeInterval(null, now);
            AddSubject(subject);
            subject = new BeginEndTimeInterval(now, now);
            AddSubject(subject);
            DateTime b = new DateTime(2000, 1, 1);
            DateTime e = new DateTime(2122, 12, 31);
            subject = new BeginEndTimeInterval(b, e);
            AddSubject(subject);

            DateTime past = new DateTime(1995, 4, 24);
            DateTime future = new DateTime(2223, 5, 13);
            m_Dates = new DateTime?[]
            {
                null, past, now, future
            };
        }
 public void TestLeastUncertainTimePointIntervalRelation6C()
 {
     DateTime? t = new DateTime(2011, 3, 12);
     ITimeInterval i = new BeginEndTimeInterval(new DateTime(1991, 11, 17), null);
     TimePointIntervalRelation result = TimePointIntervalRelation.LeastUncertain(t, i);
     //Console.WriteLine("(" + t + ", " + i + ") =:= " + result);
     Assert.AreEqual(TimePointIntervalRelation.AfterBegin, result);
 }
 public void TestLeastUncertainTimePointIntervalRelation3C()
 {
     DateTime? t = new DateTime(1995, 6, 23);
     ITimeInterval i = new BeginEndTimeInterval(null, new DateTime(2010, 3, 12));
     TimePointIntervalRelation result = TimePointIntervalRelation.LeastUncertain(t, i);
     //Console.WriteLine("(" + t + ", " + i + ") =:= " + result);
     Assert.AreEqual(TimePointIntervalRelation.BeforeEnd, result);
 }
 public void TestLeastUncertainTimePointIntervalRelation2B()
 {
     DateTime? t = DateTime.Now;
     ITimeInterval i = new BeginEndTimeInterval(null, t);
     TimePointIntervalRelation result = TimePointIntervalRelation.LeastUncertain(t, i);
     //Console.WriteLine("(" + t + ", " + i + ") =:= " + result);
     Assert.AreEqual(TimePointIntervalRelation.Ends, result);
 }
 public override void TestConstructor()
 {
     foreach (DateTime? d1 in m_Dates)
     {
         foreach (DateTime? d2 in m_Dates)
         {
             try
             {
                 AbstractBeginEndTimeInterval subject = new BeginEndTimeInterval(d1, d2);
             }
             catch (IllegalTimeIntervalException)
             {
                 // NOP
             }
         }
     }
 }