public void Partition_CorrectlyPartitionsList() { int partition = 5; Problem_04.Partition(LIST, partition); using (var e1 = LIST.GetEnumerator()) using (var e2 = PARTITIONED_LIST.GetEnumerator()) { while (e1.MoveNext() && e2.MoveNext()) { if (e1.Current != e2.Current) { Assert.Fail(); } } } }
public void PalindromePermutation_ReturnsFalseForInvalidPalindromePermutation() { var result = Problem_04.PalindromePermutation(INVALID_PALINDROME_PERMUTATION); Assert.IsFalse(result); }
public void PalindromePermutation_ReturnsTrueForValidPalindromePermutation() { var result = Problem_04.PalindromePermutation(VALID_PALINDROME_PERMUTATION); Assert.IsTrue(result); }