Esempio n. 1
0
        public string[] SelectMultiple(
            ConsoleKey[] inputSequence,
            string[] options)
        {
            if (!inputSequence.Contains(ConsoleKey.Enter))
            {
                Assert.Fail(@"Invalid input sequence for this test,
there needs to be a Enter. Otherwise the the test will hang");
            }

            var consoleMock = new ConsoleMockBuilder()
                              .WithReadKeySequence(inputSequence)
                              .Build();

            SelectMulitple sut = new SelectMulitple(consoleMock.Object);

            return(sut.Ask("Test Question??", options));
        }