ansible/test/utils/shippable/code-smell.sh
Matt Clay 71819c0a60 Test reorganization and cleanup. (#18270)
- Correct directory name in test/README.md
- Move code-smell tests to test/sanity/code-smell
- Update code-smell.sh to use new script paths
- Add test/integration/target-prefixes.win for ansible-test
- Move module unit tests to match module directory layout
2016-10-31 12:53:11 -07:00

26 lines
755 B
Bash
Executable file

#!/bin/bash -eux
source_root=$(python -c "from os import path; print(path.abspath(path.join(path.dirname('$0'), '../../..')))")
install_deps="${INSTALL_DEPS:-}"
cd "${source_root}"
if [ "${install_deps}" != "" ]; then
apt-add-repository 'deb http://archive.ubuntu.com/ubuntu trusty-backports universe'
apt-get update -qq
apt-get install shellcheck
pip install -r "${source_root}/test/utils/shippable/code-smell-requirements.txt" --upgrade
pip list
fi
yamllint .
test/sanity/code-smell/replace-urlopen.sh .
test/sanity/code-smell/use-compat-six.sh lib
test/sanity/code-smell/boilerplate.sh
test/sanity/code-smell/required-and-default-attributes.sh
shellcheck \
test/integration/targets/*/*.sh \
test/utils/shippable/*.sh