Fix bashate warnings

Three ((value++)) lines are generating this bashate warning:
E043: Arithmetic compound has inconsistent return semantics

This will now be an error when running pep8 checks.

Trivialfix

Change-Id: If7a63e550d5d27fe6716cc63c85426cd2250732f
This commit is contained in:
Brian Haley 2017-03-07 13:16:01 -05:00
parent 4118ea2e7b
commit a0552e75e3
2 changed files with 5 additions and 4 deletions

View File

@ -42,14 +42,14 @@ for test_file in ${test_files[@]}; do
if [ ! -f "$filename" ] && [ ! -d "$package_dir" ]; then
for ignore_regex in ${ignore_regexes[@]}; do
if [[ "$relative_path" =~ $ignore_regex ]]; then
((ignore_count++))
ignore_count=$((ignore_count + 1))
continue 2
fi
done
echo "Unexpected test file: $base_test_path/$relative_path"
((error_count++))
error_count=$((error_count + 1))
fi
((total_count++))
total_count=$((total_count + 1))
done
if [ "$ignore_count" -ne 0 ]; then

View File

@ -138,7 +138,8 @@ commands = bash -c "find {toxinidir} \
# E005 file does not begin with #! or have a .sh prefix
# E006 check for lines longer than 79 columns
# E042 local declaration hides errors
-print0 | xargs -0 bashate -v -iE006 -eE005,E042"
# E043 Arithmetic compound has inconsistent return semantics
-print0 | xargs -0 bashate -v -iE006 -eE005,E042,E043"
[testenv:genconfig]
commands = {toxinidir}/tools/generate_config_file_samples.sh