Bari.Core.Test.Model.DefaultSuiteFactoryTest.UsesFirstAvailableAsActiveGoalIfCommandDoesNotNeedIt C# (CSharp) Method

UsesFirstAvailableAsActiveGoalIfCommandDoesNotNeedIt() private method

        public void UsesFirstAvailableAsActiveGoalIfCommandDoesNotNeedIt()
        {
            commandEnumerator.Setup(c => c.NeedsExplicitTargetGoal(It.IsAny<string>())).Returns(false);

            var factory = new DefaultSuiteFactory(parameters.Object, suiteRoot, commandEnumerator.Object);

            var goal1 = new Goal("goal1");
            var suite = factory.CreateSuite(new HashSet<Goal>(new[] { goal1 }), Suite.DebugGoal);

            suite.ActiveGoal.Should().Be(goal1);
        }