mirror of
https://github.com/kk7ds/chirp.git
synced 2024-09-21 10:37:15 +00:00
Remove unnecessary test tools
After #5237 these are no longer necessary and duplicative.
This commit is contained in:
parent
0c6ebbceb2
commit
2bad433704
@ -1,49 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
function record_failure() {
|
||||
FAILED="$1 $FAILED"
|
||||
}
|
||||
|
||||
function unit_tests() {
|
||||
NOSE=$(which nosetests)
|
||||
if [ -x "$NOSE" ]; then
|
||||
$NOSE -v tests/unit
|
||||
else
|
||||
echo "NOTE: nosetests required for unit tests!"
|
||||
record_failure unit_tests
|
||||
fi
|
||||
}
|
||||
|
||||
function driver_tests() {
|
||||
(cd tests && ./run_tests)
|
||||
}
|
||||
|
||||
function make_supported() {
|
||||
./share/make_supported.py > /dev/null
|
||||
}
|
||||
|
||||
function style_tests() {
|
||||
./tools/checkpatch.sh
|
||||
}
|
||||
|
||||
function pep8() {
|
||||
echo "Checking for PEP8 regressions..."
|
||||
time ./tools/cpep8.sh
|
||||
}
|
||||
|
||||
if test -z "${TESTS[*]}"; then
|
||||
TESTS=( unit_tests driver_tests make_supported style_tests pep8 )
|
||||
fi
|
||||
for testname in "${TESTS[@]}"; do
|
||||
eval "$testname" || record_failure "$testname"
|
||||
done
|
||||
|
||||
echo "================================================"
|
||||
|
||||
if [ -z "$FAILED" ]; then
|
||||
echo Tests OK
|
||||
else
|
||||
failed=$(echo $FAILED | sed 's/ /, /g' | sed 's/_/ /g')
|
||||
echo Tests FAILED: $failed
|
||||
exit 1
|
||||
fi
|
@ -1,21 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
# Runs cpep.py with the proper verion of the pep8 library.
|
||||
|
||||
PEP8_VERSION="1.6.2"
|
||||
|
||||
TOOLS_DIR="$(dirname $0)"
|
||||
VENV="${TMPDIR:-${TOOLS_DIR}}/cpep8.venv"
|
||||
|
||||
virtualenv="$(which virtualenv)"
|
||||
if [ ! -x "$virtualenv" ]; then
|
||||
echo 'Please install virtualenv'
|
||||
exit 1
|
||||
fi
|
||||
if [ ! -d "$VENV" ]; then
|
||||
virtualenv "$VENV"
|
||||
fi
|
||||
|
||||
source ${VENV}/bin/activate
|
||||
pip install pep8==${PEP8_VERSION} >${VENV}/pep8.log 2>&1
|
||||
${TOOLS_DIR}/cpep8.py "$@"
|
||||
deactivate
|
Loading…
Reference in New Issue
Block a user