public void Parse_sequence_verb_with_multi_instance_returns_verb_instance() { var expected = new SequenceOptions { LongSequence = new long[] { }, StringSequence = new[] { "s1", "s2" } }; var result = InvokeChoose( new[] { typeof(Add_Verb), typeof(Commit_Verb), typeof(Clone_Verb), typeof(SequenceOptions) }, new[] { "sequence", "-s", "s1", "-s", "s2" }, true); Assert.IsType <SequenceOptions>(((Parsed <object>)result).Value); expected.Should().BeEquivalentTo(((Parsed <object>)result).Value); }
public void Parse_sequence_verb_with_separator_returns_verb_instance(string[] arguments, string[] expectedString) { // Fixture setup var expected = new SequenceOptions { LongSequence = new long[] { }, StringSequence = expectedString }; // Exercize system var result = InvokeChoose( new[] { typeof(Add_Verb), typeof(Commit_Verb), typeof(Clone_Verb), typeof(SequenceOptions) }, arguments); // Verify outcome Assert.IsType <SequenceOptions>(((Parsed <object>)result).Value); expected.Should().BeEquivalentTo(((Parsed <object>)result).Value); // Teardown }
public void Parse_sequence_verb_returns_verb_instance() { // Fixture setup var expected = new SequenceOptions { LongSequence = new long[] { }, StringSequence = new[] { "aa", "b" } }; // Exercize system var result = InvokeChoose( new[] { typeof(Add_Verb), typeof(Commit_Verb), typeof(Clone_Verb), typeof(SequenceOptions) }, new[] { "sequence", "-s", "aa", "b" }); // Verify outcome Assert.IsType <SequenceOptions>(((Parsed <object>)result).Value); expected.Should().BeEquivalentTo(((Parsed <object>)result).Value); // Teardown }