Scaffolding projects with testing

This commit is contained in:
2020-11-17 14:32:01 -07:00
parent e208cee794
commit 0bbe1316b1
8 changed files with 67 additions and 13 deletions

30
test-projects.sh Normal file
View File

@@ -0,0 +1,30 @@
#! /bin/bash
# Test the Kiss projects. If run manually, this runs extra manual tests that may involve GUI stuff.
PROJECT_DIRS=projects/**/
for PROJECT_DIR in $PROJECT_DIRS
do
AUTO_TEST_FILE=${PROJECT_DIR}test.sh
if [ -e $AUTO_TEST_FILE ]
then
echo $AUTO_TEST_FILE
$AUTO_TEST_FILE
if [ ! $? -eq 0 ]
then
echo "failed"
exit 1
fi
fi
MANUAL_TEST_FILE=${PROJECT_DIR}manual-test.sh
if [ -z "$KISS_HEADLESS" ] && [ -e $MANUAL_TEST_FILE ]
then
echo $MANUAL_TEST_FILE
$MANUAL_TEST_FILE
if [ ! $? -eq 0 ]
then
echo "failed"
exit 1
fi
fi
done