Ejemplo n.º 1
0
        public void can_set_nullable_default_values()
        {
            var args = NativeMethods.CommandLineToArgs("-s 100");
            var simple = new CommandLineArgs();
            var result = simple.CliParse(args);

            Assert.AreEqual(true, result.Successful);
            Assert.AreEqual(0, result.CliParseMessages.ToList().Count);
            Assert.AreEqual(false, result.ShowHelp);
            Assert.AreEqual(100, simple.Seed);
        }
Ejemplo n.º 2
0
        public void can_set_implied_defaulted_values()
        {
            var args = NativeMethods.CommandLineToArgs("100");
            var simple = new CommandLineArgs();
            var result = simple.CliParse(args);

            Assert.AreEqual(true, result.Successful,"Successful");
            Assert.AreEqual(0, result.CliParseMessages.ToList().Count);
            Assert.AreEqual(false, result.ShowHelp);
            Assert.AreEqual(100, simple.ImpliedDefault);
        }