static private IterationTimeSpanFromString ( string iterationLength ) : System.TimeSpan | ||
iterationLength | string | dd.hhmmss |
Résultat | System.TimeSpan |
public void TestIterationTimeSpanFromStringOneDay() { TimeSpan result = VistaDateTimeIterator.IterationTimeSpanFromString("1."); Assert.AreEqual(1, result.Days); Assert.AreEqual(0, result.Hours); Assert.AreEqual(0, result.Minutes); Assert.AreEqual(0, result.Seconds); }
public void TestIterationTimeSpanFromStringTooManySeconds() { TimeSpan result = VistaDateTimeIterator.IterationTimeSpanFromString("1.250290"); Assert.AreEqual(2, result.Days); Assert.AreEqual(1, result.Hours); Assert.AreEqual(3, result.Minutes); Assert.AreEqual(30, result.Seconds); }
public void TestIterationTimeSpanFromStringOhOne() { TimeSpan result = VistaDateTimeIterator.IterationTimeSpanFromString("01"); Assert.AreEqual(1, result.Hours); }