mirror of
https://github.com/sinseman44/PyCNC.git
synced 2026-07-16 08:37:09 +00:00
check if pycnc is installed
This commit is contained in:
+7
-2
@@ -13,8 +13,13 @@ echo '**********************************************************************'
|
|||||||
echo '---------------------------Unit tests---------------------------------'
|
echo '---------------------------Unit tests---------------------------------'
|
||||||
python -m unittest discover "$@" --pattern="test_*.py"
|
python -m unittest discover "$@" --pattern="test_*.py"
|
||||||
echo '-------------------------Integration tests----------------------------'
|
echo '-------------------------Integration tests----------------------------'
|
||||||
res="$(pycnc tests/rects.gcode 2>&1)"
|
app="pycnc"
|
||||||
res="$res$(pycnc tests/test_parser.gcode 2>&1)"
|
if ! which $app 2&> /dev/null; then
|
||||||
|
echo "WARNING pycnc not found in path. Not installed? Using './pycnc'."
|
||||||
|
app="./pycnc"
|
||||||
|
fi
|
||||||
|
res="$($app tests/rects.gcode 2>&1)"
|
||||||
|
res="$res$($app tests/test_parser.gcode 2>&1)"
|
||||||
if echo "$res" | grep -q -i error; then
|
if echo "$res" | grep -q -i error; then
|
||||||
echo "FAILED"
|
echo "FAILED"
|
||||||
echo "$res"
|
echo "$res"
|
||||||
|
|||||||
Reference in New Issue
Block a user