public void IntegerEnsureMaxIsNotExceeded() { // Arrange Integer my_int = new Integer(); // Act int[] actual = my_int.GetSequence(my_int.Max+1); // This is a call the uses an older testing framework. (e.g. Koans) //Assert.Throws(typeof(Exception), my_int.GetSequence(my_int.Max)); }
public void IntegerEnsureICanCreateASequenceOfTenIntegers() { // Arrange Integer my_int = new Integer(); // Act int[] actual = my_int.GetSequence(10); int[] expected = { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 }; // Assert CollectionAssert.AreEqual(expected, actual); }