Skip to content

Commit 5134059

Browse files
davidcokdavidcok
and
davidcok
authored
Adding tests for attribute help and other help (#3964)
<small>By submitting this pull request, I confirm that my contribution is made under the terms of the [MIT license](https://github.com/dafny-lang/dafny/blob/master/LICENSE.txt).</small> --------- Co-authored-by: davidcok <[email protected]>
1 parent 99723e9 commit 5134059

File tree

4 files changed

+10
-1
lines changed

4 files changed

+10
-1
lines changed

Source/XUnitExtensions/Lit/ILitCommand.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,9 @@ public static Token[] Tokenize(string line) {
6666
kind = Kind.Verbatim;
6767
}
6868
} else {
69-
if (c is '*' or '?' && !singleQuoted) {
69+
if (c is '?' && inProgressArgument.Length == 1 && inProgressArgument[0] == '-') {
70+
kind = Kind.Verbatim;
71+
} else if (c is '*' or '?' && !singleQuoted) {
7072
kind = Kind.MustGlob;
7173
}
7274
inProgressArgument.Append(c);

Test/attr-help.dfy

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
// RUN: %baredafny /attrHelp
2+
3+
// Just checks that the attribute help option works

Test/legacy-help.dfy

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
// RUN: %baredafny -?

Test/new-cli-help.dfy

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
// RUN: %baredafny -h > "%t"
2+
// RUN: %baredafny --help > "%t_X"
3+
// RUN: %diff "%t" "%t_X"

0 commit comments

Comments
 (0)