-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove .err file if test succeeds; enable -shell option.
- Loading branch information
Showing
7 changed files
with
51 additions
and
9 deletions.
There are no files selected for viewing
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
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
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
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 |
---|---|---|
@@ -1,14 +1,27 @@ | ||
|
||
$ cp $TESTDIR/errfile/*.t . | ||
$ mkdir sub | ||
$ echo ' $ true' > sub/pass.t | ||
$ echo ' $ false' > sub/fail.t | ||
|
||
$ grill pass.t >/dev/null 2>&1 | ||
|
||
$ grill fail.t >/dev/null 2>&1 | ||
$ grill -quiet sub/*.t | ||
!. | ||
# Ran 2 tests, 0 skipped, 1 failed. | ||
[1] | ||
|
||
Error files are written out only for failed suites. | ||
|
||
$ ls | ||
$ ls sub/ | ||
fail.t | ||
fail.t.err | ||
pass.t | ||
|
||
If test starts passing, err file is removed | ||
|
||
$ echo ' $ true' > sub/fail.t | ||
$ grill -quiet sub/*.t | ||
.. | ||
# Ran 2 tests, 0 skipped, 0 failed. | ||
|
||
$ ls sub/ | ||
fail.t | ||
pass.t |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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,19 @@ | ||
-shell option sets the interpreter used to run the test. | ||
|
||
$ cat > check-sh.t <<EOF | ||
> $ echo \$0 | ||
> /bin/sh (glob) | ||
> EOF | ||
|
||
$ cat > check-bash.t <<EOF | ||
> $ echo \$0 | ||
> /bin/bash (glob) | ||
> EOF | ||
|
||
$ grill check-sh.t | ||
. | ||
# Ran 1 test, 0 skipped, 0 failed. | ||
|
||
$ grill -shell=/bin/bash check-bash.t | ||
. | ||
# Ran 1 test, 0 skipped, 0 failed. |