Пример #1
0
        private void Anything_selected_does_not_trigger_action_base_test(GetGitChangeDirectoryCommandOptions options)
        {
            var testCmd = new ActionDefault(_repoPaths, options, _hitManager);

            var result = testCmd.Process(_info);

            Assert.False(result);
            _hitManager.Received(0).GetHitList();
        }
Пример #2
0
        public void Not_set_returns_list_and_prompt()
        {
            _hitManager.GetHitList().Returns(new List <HitData>());
            var options = new GetGitChangeDirectoryCommandOptions {
            };
            var testCmd = new ActionDefault(_repoPaths, options, _hitManager);

            var result = testCmd.Process(_info);

            Assert.True(result);

            _hitManager.Received(1).GetHitList();
            Assert.True(_info.PromptForListSelector);
            Assert.True(_info.Options.List);
            CollectionAssert.IsEmpty(_info.ListData);
        }