public void MultipleBooleanFlags() { BooleanFlag flag = new BooleanFlag(); Assert.IsFalse(flag.Apple); Assert.IsFalse(flag.Baby); Assert.IsFalse(flag.LikeCardinals); ConsoleArgs <BooleanFlag> .Populate("ConsoleArgs.dll -a --b -c", flag); // Validate the populated settings. Assert.IsTrue(flag.Apple); Assert.IsTrue(flag.Baby); Assert.IsTrue(flag.LikeCardinals); }
public void DoubleDashBooleanWord() { BooleanFlag flag = new BooleanFlag(); Assert.IsFalse(flag.Apple); Assert.IsFalse(flag.Baby); Assert.IsFalse(flag.LikeCardinals); ConsoleArgs <BooleanFlag> .Populate("ConsoleArgs.dll --apple", flag); // Validate the populated settings. Assert.IsTrue(flag.Apple); Assert.IsFalse(flag.Baby); Assert.IsFalse(flag.LikeCardinals); }