list_all_channels now serves as a good template to use for other funcs to follow suit
This commit is contained in:
parent
fb63007a85
commit
c490343442
@ -1,23 +1,23 @@
|
|||||||
#!/bin/sh
|
#!/bin/bash
|
||||||
|
|
||||||
# Available tests marked with `TEST`
|
# Available tests marked with `TEST` - ez grep usage
|
||||||
|
|
||||||
active_tests='list_all_channels'
|
active_tests='list_all_channels'
|
||||||
|
|
||||||
list_all_channels() { # TEST
|
list_all_channels() { # TEST
|
||||||
echo $arrows Test: list_all_channels : ...
|
result=$(curl --silent -i $GET $url/channels/list -d $simple_key)
|
||||||
curl $GET $url/channels/list -d $simple_key
|
code=$(echo "$result" | grep HTTP\/1.1 | awk '{print $2}')
|
||||||
echo '\n'$line
|
echo "good_list_all_channels" 200 $code
|
||||||
|
show_discrepancy 200 $code "$result"
|
||||||
}
|
}
|
||||||
|
|
||||||
if [ -z $1 ];then
|
if [ -z $1 ];then
|
||||||
. ./tests/common.sh
|
|
||||||
echo Running tests $active_tests
|
|
||||||
for cmd in $active_tests;do
|
for cmd in $active_tests;do
|
||||||
$cmd
|
$cmd
|
||||||
done
|
done
|
||||||
else
|
else
|
||||||
for cmd in $@;do
|
for cmd in $@;do
|
||||||
$cmd
|
$cmd
|
||||||
|
echo '\n'$?
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user