Only execute lint unit tests for the tests repo
We only need to execute the lint tests for the tests repo, not all repositories. The path being used is not suitable when executed in other repositories. Change-Id: I8afbf53304ad9ac150ff6ddc3d44d256dadadd96
This commit is contained in:
parent
89e3c66946
commit
44761d390b
@ -42,7 +42,11 @@ echo "ANSIBLE_LINT_PARAMS: ${ANSIBLE_LINT_PARAMS}"
|
||||
source "${COMMON_TESTS_PATH}/test-ansible-env-prep.sh"
|
||||
|
||||
# Run unit tests for OSA ansible-lint rules
|
||||
# Only do it if the repository being tested is the openstack-ansible-tests
|
||||
# repository.
|
||||
if [[ "$(basename ${WORKING_DIR})" == "openstack-ansible-tests" ]]; then
|
||||
python -m unittest discover -s "${WORKING_DIR}/ansible-lint" -p 'Test*.py'
|
||||
fi
|
||||
|
||||
# Execute ansible-lint. We do not want to test dependent roles located
|
||||
# in $HOME/.ansible/roles since we only care about the role we are currently
|
||||
|
Loading…
Reference in New Issue
Block a user