예제 #1
0
        public void ToString_NoFormat()
        {
            LocalTime  time       = new LocalTime(14, 15, 12, 123);
            Offset     offset     = Offset.FromHours(1);
            OffsetTime offsetDate = new OffsetTime(time, offset);

            using (CultureSaver.SetCultures(CultureInfo.InvariantCulture))
            {
                Assert.AreEqual("14:15:12+01", offsetDate.ToString());
            }
        }
예제 #2
0
        public void ToString_NoFormat()
        {
            LocalDate  date       = new LocalDate(2012, 10, 6);
            Offset     offset     = Offset.FromHours(1);
            OffsetDate offsetDate = new OffsetDate(date, offset);

            using (CultureSaver.SetCultures(CultureInfo.InvariantCulture))
            {
                Assert.AreEqual("2012-10-06+01", offsetDate.ToString());
            }
        }