public void CanGetLocalTime12h24h() { var utcTime = new DateTime(2019, 6, 1, 0, 30, 0); Assert.Equal("5:30 PM", TimeZoneConverter.GetLocalTime(utcTime)); Assert.Equal("17:30", TimeZoneConverter.GetLocalTime24h(utcTime)); }
public void CanGetLocalTime12h24h() { var dt = new DateTime(2019, 6, 1, 17, 30, 0); Assert.Equal(TimeZoneConverter.GetLocalTime(dt), "5:30 PM"); Assert.Equal(TimeZoneConverter.GetLocalTime24h(dt), "17:30"); }