public void RangeSetSeriesConstructorTest() { List <RangeSet> tempRange = GenerateTempRange(); RangeSetSeries target = new RangeSetSeries(tempRange); Assert.AreEqual(target.Count, 2); }
public void ToStringTest() { List <RangeSet> tempRange = GenerateTempRange(); RangeSetSeries target = new RangeSetSeries(tempRange); // TODO: Initialize to an appropriate value string expected = "{1-2,4-5},{11-12,14-15}"; // TODO: Initialize to an appropriate value var actual = target.ToString(); Assert.AreEqual(expected, actual); }
public void ToStringTest() { List<RangeSet> tempRange = GenerateTempRange(); RangeSetSeries target = new RangeSetSeries( tempRange ); // TODO: Initialize to an appropriate value string expected = "{1-2,4-5},{11-12,14-15}"; // TODO: Initialize to an appropriate value string actual; actual = target.ToString(); Assert.AreEqual( expected, actual ); }
public void TryParseTestNonError() { string rangeString = "{1-2,4-5},{11-12,14-15}"; // TODO: Initialize to an appropriate value // TODO: Initialize to an appropriate value RangeSetSeries outputExpected = new RangeSetSeries(GenerateTempRange()); // TODO: Initialize to an appropriate value var actual = RangeSetSeries.TryParse(rangeString, out RangeSetSeries output); Assert.AreEqual(outputExpected, output); Assert.AreEqual(true, actual); }
public void TryParseTestFail() { string error = null; // TODO: Initialize to an appropriate value string rangeString = "{1-2,4-5},{11-12,14-15"; // TODO: Initialize to an appropriate value RangeSetSeries output = null; // TODO: Initialize to an appropriate value RangeSetSeries outputExpected = null; // TODO: Initialize to an appropriate value bool expected = false; // TODO: Initialize to an appropriate value bool actual; actual = RangeSetSeries.TryParse(ref error, rangeString, out output); Assert.IsNotNull(error); Assert.AreEqual(outputExpected, output); Assert.AreEqual(expected, actual); }
public void TryParseTestSuccess() { string error = null; // TODO: Initialize to an appropriate value string errorExpected = null; // TODO: Initialize to an appropriate value string rangeString = "{1-2,4-5},{11-12,14-15}"; // TODO: Initialize to an appropriate value RangeSetSeries output = null; // TODO: Initialize to an appropriate value RangeSetSeries outputExpected = new RangeSetSeries(GenerateTempRange()); // TODO: Initialize to an appropriate value bool expected = true; // TODO: Initialize to an appropriate value bool actual; actual = RangeSetSeries.TryParse(ref error, rangeString, out output); Assert.AreEqual(errorExpected, error); Assert.AreEqual(outputExpected, output); Assert.AreEqual(expected, actual); }
public void RangeSetSeriesConstructorTest() { List<RangeSet> tempRange = GenerateTempRange(); RangeSetSeries target = new RangeSetSeries( tempRange ); Assert.AreEqual( target.Count, 2 ); }
public void TryParseTestSuccess() { string error = null; // TODO: Initialize to an appropriate value string errorExpected = null; // TODO: Initialize to an appropriate value string rangeString = "{1-2,4-5},{11-12,14-15}"; // TODO: Initialize to an appropriate value RangeSetSeries output = null; // TODO: Initialize to an appropriate value RangeSetSeries outputExpected = new RangeSetSeries( GenerateTempRange() ); // TODO: Initialize to an appropriate value bool expected = true; // TODO: Initialize to an appropriate value bool actual; actual = RangeSetSeries.TryParse( ref error, rangeString, out output ); Assert.AreEqual( errorExpected, error ); Assert.AreEqual( outputExpected, output ); Assert.AreEqual( expected, actual ); }