public void DetailedHelpWithMissingRequired() { var options = new ComplexOptionsWithHelp(); bool result = new CommandLineParser(new CommandLineParserSettings(Console.Out)).ParseArguments( new string[] { "-j0" }, options); Assert.IsFalse(result); }
public void DetailedHelpWithBadMutualExclusiveness() { var options = new ComplexOptionsWithHelp(); bool result = new CommandLineParser(new CommandLineParserSettings(true, true, Console.Out)).ParseArguments( new string[] { "-iIN.FILE", "-oOUT.FILE", "--offset", "99", "-ap" }, options); Assert.IsFalse(result); }
public void Detailed_help_with_bad_format_and_mutual_exclusiveness() { var options = new ComplexOptionsWithHelp(); bool result = new CommandLine.Parser(new ParserSettings(true, true, Console.Out)).ParseArguments( new string[] { "-iIN.FILE", "-oOUT.FILE", "--offset", "zero", "-pa" }, options); result.Should().BeFalse(); }
public void DetailedHelpWithBadFormat() { var options = new ComplexOptionsWithHelp(); bool result = new CommandLineParser(new CommandLineParserSettings(Console.Out)).ParseArguments( new string[] { "-iIN.FILE", "-oOUT.FILE", "--offset", "abc" }, options); Assert.IsFalse(result); }
public void Detailed_help_with_missing_required_and_bad_format() { var options = new ComplexOptionsWithHelp(); bool result = new CommandLine.Parser(new ParserSettings(Console.Out)).ParseArguments( new string[] { "-i0" }, options); result.Should().BeFalse(); }
public void Detailed_help_with_bad_format() { var options = new ComplexOptionsWithHelp(); bool result = new CommandLine.Parser(new ParserSettings(Console.Out)).ParseArguments( new string[] { "-iIN.FILE", "-oOUT.FILE", "--offset", "abc" }, options); result.Should().BeFalse(); }
public void Detailed_help_with_bad_mutual_exclusiveness() { var options = new ComplexOptionsWithHelp(); bool result = new CommandLine.Parser(new ParserSettings(true, true, Console.Out)).ParseArguments( new string[] { "-iIN.FILE", "-oOUT.FILE", "--offset", "0", "-ap" }, options); result.Should().BeFalse(); }
public void DetailedHelpWithMissingRequiredAndBadFormat() { var options = new ComplexOptionsWithHelp(); bool result = new CommandLineParser(new CommandLineParserSettings(Console.Out)).ParseArguments( new string[] { "-i0" }, options); result.Should().Be.False(); }
public void DetailedHelpWithBadFormatAndMutualExclusiveness() { var options = new ComplexOptionsWithHelp(); bool result = new CommandLineParser(new CommandLineParserSettings(true, true, Console.Out)).ParseArguments( new string[] { "-iIN.FILE", "-oOUT.FILE", "--offset", "zero", "-pa" }, options); result.Should().Be.False(); }
public void DetailedHelpWithBadMutualExclusiveness() { var options = new ComplexOptionsWithHelp(); bool result = new CommandLineParser(new CommandLineParserSettings(true, true, Console.Out)).ParseArguments( new string[] { "-iIN.FILE", "-oOUT.FILE", "--offset", "0", "-ap" }, options); Assert.IsFalse(result); }