test
This commit is contained in:
@ -5,7 +5,8 @@ env: NGROK_TOKEN=1c1uvy5CSMYBuO3o7Jv3xgRugYF_XGEz3Atyjb7KMaxw5GeU
|
|||||||
before_install:
|
before_install:
|
||||||
- sudo apt-get update
|
- sudo apt-get update
|
||||||
- sudo apt-get install zfsutils-linux
|
- sudo apt-get install zfsutils-linux
|
||||||
|
|
||||||
script:
|
script:
|
||||||
- sudo -E ./ngrok.sh
|
# - sudo -E ./ngrok.sh
|
||||||
- sudo -E ./run_tests
|
- sudo -E ./run_tests
|
||||||
# - sudo -E pip --version
|
# - sudo -E pip --version
|
||||||
|
|||||||
11
run_tests
11
run_tests
@ -1,9 +1,16 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
#reactivate python environment, if any (usefull in Travis)
|
#reactivate python environment, if any (usefull in Travis)
|
||||||
source $VIRTUAL_ENV/bin/activate
|
source $VIRTUAL_ENV/bin/activate || true
|
||||||
|
|
||||||
coverage run --source bin.zfs_autobackup -m unittest -v $@
|
# test needs ssh access to localhost for testing
|
||||||
|
if ! [ -t ~/.ssh/id_rsa ]; then
|
||||||
|
ssh-keygen -t rsa -f ~/.ssh/id_rsa -P '' || exit 1
|
||||||
|
cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_keys || exit 1
|
||||||
|
ssh -oStrictHostKeyChecking=accept-new localhost true || exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
coverage run --source bin.zfs_autobackup -m unittest -v $@
|
||||||
EXIT=$?
|
EXIT=$?
|
||||||
|
|
||||||
echo
|
echo
|
||||||
|
|||||||
Reference in New Issue
Block a user