Ejemplo n.º 1
0
        public void Help_ShouldReturnCommandSetup()
        {
            var parser        = A.Fake <Parser>();
            var commandParser = A.Fake <CommandParser <Command1Options> >();

            var setup = new DefaultCommandSetup <Command1Options>(parser, commandParser);

            setup.Help("helpText").Should().Be(setup);
        }
Ejemplo n.º 2
0
        public void Help_ShouldAssignHelpTextToCommandParser()
        {
            var parser        = A.Fake <Parser>();
            var commandParser = A.Fake <CommandParser <Command1Options> >();

            var setup = new DefaultCommandSetup <Command1Options>(parser, commandParser);

            setup.Help("newHelpText");

            A.CallToSet(() => commandParser.CommandHelp).To("newHelpText").MustHaveHappened();
        }