-
Notifications
You must be signed in to change notification settings - Fork 480
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add tests for several double-dash scenarios
Double dash (--) should end option sequences, but should have no effect on value sequences. These unit tests reflect that design.
- Loading branch information
Showing
3 changed files
with
101 additions
and
0 deletions.
There are no files selected for viewing
15 changes: 15 additions & 0 deletions
15
tests/CommandLine.Tests/Fakes/Options_With_Value_Sequence_And_Subsequent_Value.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
// Copyright 2005-2015 Giacomo Stelluti Scala & Contributors. All rights reserved. See License.md in the project root for license information. | ||
|
||
using System.Collections.Generic; | ||
|
||
namespace CommandLine.Tests.Fakes | ||
{ | ||
class Options_With_Value_Sequence_And_Subsequent_Value | ||
{ | ||
[Value(0)] | ||
public IEnumerable<string> StringSequence { get; set; } | ||
|
||
[Value(1)] | ||
public string NeverReachedValue { get; set; } | ||
} | ||
} |
15 changes: 15 additions & 0 deletions
15
tests/CommandLine.Tests/Fakes/Options_With_Value_Sequence_With_Max_And_Subsequent_Value.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
// Copyright 2005-2015 Giacomo Stelluti Scala & Contributors. All rights reserved. See License.md in the project root for license information. | ||
|
||
using System.Collections.Generic; | ||
|
||
namespace CommandLine.Tests.Fakes | ||
{ | ||
class Options_With_Value_Sequence_With_Max_And_Subsequent_Value | ||
{ | ||
[Value(0, Max=2)] | ||
public IEnumerable<string> StringSequence { get; set; } | ||
|
||
[Value(1)] | ||
public string NeverReachedValue { get; set; } | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters