Remove tide test install flag

This commit is contained in:
Ilan Cosman 2021-01-22 16:09:36 -08:00
parent ca4cdb022b
commit 8554ab3145
2 changed files with 8 additions and 13 deletions

View File

@ -43,7 +43,7 @@ Anything exposed to the shell or user--functions, global/universal variables, an
- [Fishtape][] - 100% _pure_-Fish test runner
- [Clownfish][] - Override the behavior of commands
You can quickly install the necessary dependencies using `tide test -i`.
You can install the necessary dependencies using `fisher install jorgebucaran/fishtape ilancosman/clownfish`.
`tide test` runs tests from the `$_tide_root/functions/tide/tests` directory.

View File

@ -1,17 +1,13 @@
function _tide_sub_test
argparse 'h/help' 'v/verbose' 'a/all' 'i/install' 'c-CI' -- $argv
argparse 'h/help' 'v/verbose' 'a/all' 'c-CI' -- $argv
if set -q _flag_help
_tide_test_help
return 0
else if set -q _flag_install
# Install fisher, fishtape, and clownfish for testing
fisher install jorgebucaran/fishtape IlanCosman/clownfish
return 0
else if not functions --query fishtape mock
set -l b (set_color -o || echo)
set -l n (set_color normal || echo)
printf '%s\n' $b'fishtape'$n' and'$b' clownfish'$n' must be installed to to run Tide\'s test suite. You can install them with'$b' tide test -i'$n
printf '%s\n' $b'fishtape'$n' and'$b' clownfish'$n' must be installed to to run Tide\'s test suite.'$n
return 1
end
@ -45,11 +41,6 @@ function _tide_sub_test
end
end
if test -e $passed
printf '%s\n' '--------PASSED--------'
cat $passed
rm $passed
end
if test -e $failed
printf '%s\n' '--------FAILED--------'
cat $failed
@ -57,6 +48,11 @@ function _tide_sub_test
return 1
end
if test -e $passed
printf '%s\n' '--------PASSED--------'
cat $passed
rm $passed
end
end
function _tide_test_help
@ -67,6 +63,5 @@ function _tide_test_help
' -v or --verbose print test output even if passed' \
' -a or --all run all available tests' \
' -h or --help print this help message' \
' -i or --install install testing dependencies' \
' --CI run tests designed for CI'
end