Skip to content

Commit

Permalink
Merge commit 'c1276d1a079e9f7f1c5e739e5e440f22f8a44e17' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
hyperupcall committed Oct 19, 2021
2 parents d92967e + c1276d1 commit 545ad58
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion bats-assert/src/assert_line.bash
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ assert_line() {
while (( $# > 0 )); do
case "$1" in
-n|--index)
if (( $# < 2 )) || ! [[ $2 =~ ^([0-9]|[1-9][0-9]+)$ ]]; then
if (( $# < 2 )) || ! [[ $2 =~ ^-?([0-9]|[1-9][0-9]+)$ ]]; then
echo "\`--index' requires an integer argument: \`$2'" \
| batslib_decorate 'ERROR: assert_line' \
| fail
Expand Down
2 changes: 1 addition & 1 deletion bats-assert/src/refute_line.bash
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ refute_line() {
while (( $# > 0 )); do
case "$1" in
-n|--index)
if (( $# < 2 )) || ! [[ $2 =~ ^([0-9]|[1-9][0-9]+)$ ]]; then
if (( $# < 2 )) || ! [[ $2 =~ ^-?([0-9]|[1-9][0-9]+)$ ]]; then
echo "\`--index' requires an integer argument: \`$2'" \
| batslib_decorate 'ERROR: refute_line' \
| fail
Expand Down

0 comments on commit 545ad58

Please sign in to comment.