public void NotValidArray() { string[] firstArray = null; string[] secondArray = { }; bool result = _permutationService.CompareArrays(firstArray, secondArray); Assert.IsFalse(result); }
static void Main() { string[] firstArray; string[] secondArray; PermutationService _permutationService = new PermutationService(); Console.WriteLine("Please enter the first array - separate elements using spaces"); firstArray = Console.ReadLine().Split(" "); CheckArrayLength(firstArray); CheckElementsAreIntegers(firstArray); Console.WriteLine("Please enter the second array - separate elements using spaces"); secondArray = Console.ReadLine().Split(" "); CheckArrayLength(secondArray); CheckElementsAreIntegers(secondArray); if (_permutationService.CompareArrays(firstArray, secondArray)) { Console.WriteLine("YES"); } else { Console.WriteLine("NO"); } Console.Read(); }