public DiaryPresenter(IClock clock, Diary diary, License license) { this.clock = clock; this.diary = diary; this.license = license; Debug.WriteLine("DiaryPresenter Constructor"); }
public void FormatTodayIsoUtc() { var c = new StubClock(Instant.UnixEpoch); var d = new Diary(c, CalendarSystem.Iso, DateTimeZone.Utc); string t = d.FormatToday(); Assert.AreEqual("1970-01-01",t); Debug.WriteLine("Diary says FormatTodayIsoUtc is:" + t); }
public void FormatTodayIsoNegativeOffset() { var c = new StubClock(Instant.UnixEpoch); var z = DateTimeZone.ForId("America/New_York"); var d = new Diary(c, CalendarSystem.Iso, z); string t = d.FormatToday(); Assert.AreEqual("1969-12-31", t); Debug.WriteLine("Diary says FormatTodayIsoUtc is:" + t); }
private static void ManualDependencyInjectionTest() { var c = SystemClock.Instance; var l = new License(Instant.UnixEpoch, c); var d = new Diary(c, CalendarSystem.Iso, DateTimeZone.GetSystemDefault()); var p = new DiaryPresenter(c, d, l); p.Start(); }