mirror of https://github.com/jorgebucaran/fisher
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
27 lines
564 B
Fish
27 lines
564 B
Fish
set -g gist $DIRNAME/fixtures/gist
|
|
|
|
function -S setup
|
|
function -S spin -a url
|
|
cat $gist/(basename $url).json ^ /dev/null
|
|
end
|
|
end
|
|
|
|
function -S teardown
|
|
functions -e spin
|
|
end
|
|
|
|
test "$TESTNAME - Fail if URL is an empty string"
|
|
1 -eq (
|
|
__fisher_gist_to_name ""
|
|
printf $status
|
|
)
|
|
end
|
|
|
|
test "$TESTNAME - Fail if URL is invalid"
|
|
-z (__fisher_gist_to_name gist.github.com/bar)
|
|
end
|
|
|
|
test "$TESTNAME - Retrieve the name of the first *.fish file in the JSON stream"
|
|
foo = (__fisher_gist_to_name gist.github.com/foo)
|
|
end
|