start of basic api tests, all tests still individually runnable
This commit is contained in:
parent
0df6702a9d
commit
2b70d37370
15
server/tests/common.sh
Normal file
15
server/tests/common.sh
Normal file
@ -0,0 +1,15 @@
|
||||
# Details for our bs user when testing things
|
||||
export id=1
|
||||
export secret=secret
|
||||
export name=godrah
|
||||
export joindate=123
|
||||
export status=1
|
||||
export permissions=69
|
||||
|
||||
export simple_key='{"secret":"secret"}'
|
||||
|
||||
export url='localhost:8888'
|
||||
|
||||
export GET='-X GET'
|
||||
export POST='-X POST'
|
||||
|
@ -1,13 +1,5 @@
|
||||
#!/bin/sh
|
||||
|
||||
# Details for our bs user when testing things
|
||||
export id=1
|
||||
export secret=secret
|
||||
export name=godrah
|
||||
export joindate=123
|
||||
export status=1
|
||||
export permissions=69
|
||||
|
||||
# This script is basically just a convenient launch pad script for running all
|
||||
# the tests at once
|
||||
# Most tests should be runnable by doing ./script.sh name_of_test
|
19
server/tests/status.md
Normal file
19
server/tests/status.md
Normal file
@ -0,0 +1,19 @@
|
||||
# State of Tests
|
||||
|
||||
Here is a description of what is passing and what is failing where
|
||||
|
||||
## Full passes
|
||||
|
||||
_Nothing for now_
|
||||
|
||||
## Basic Passes
|
||||
|
||||
_Nothing for now_
|
||||
|
||||
## Err Passes
|
||||
|
||||
_Nothing for now_
|
||||
|
||||
## Mal Passes
|
||||
|
||||
_Nothing for now_
|
@ -1,3 +1,22 @@
|
||||
#!/bin/sh
|
||||
|
||||
echo Basic tests here
|
||||
# Available tests marked with `TEST`
|
||||
|
||||
active_tests='list_all_channels'
|
||||
|
||||
list_all_channels() { # TEST
|
||||
#echo curl $GET $url/channels/list -d $simple_key
|
||||
curl $GET $url/channels/list -d $simple_key
|
||||
}
|
||||
|
||||
if [ -z $1 ];then
|
||||
. ./tests/common.sh
|
||||
echo Running tests $active_tests
|
||||
for cmd in $active_tests;do
|
||||
$cmd
|
||||
done
|
||||
else
|
||||
for cmd in $@;do
|
||||
$cmd
|
||||
done
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user