tests: Add yamllint of the lifted playbooks
This commit is contained in:
parent
4da569442c
commit
de314a0046
@ -5,6 +5,7 @@ RUN dnf -y install \
|
||||
libselinux-python3 \
|
||||
make \
|
||||
pykickstart \
|
||||
python3-ansible-runner \
|
||||
python3-coverage \
|
||||
python3-coveralls \
|
||||
python3-flask \
|
||||
@ -33,6 +34,7 @@ RUN dnf -y install \
|
||||
pbzip2 \
|
||||
squashfs-tools \
|
||||
qemu-img \
|
||||
yamllint \
|
||||
which && \
|
||||
touch /.in-container
|
||||
RUN useradd weldr
|
||||
|
2
Makefile
2
Makefile
@ -43,6 +43,8 @@ install: all
|
||||
check:
|
||||
@echo "*** Running pylint ***"
|
||||
PYTHONPATH=$(PYTHONPATH):./src/ ./tests/pylint/runpylint.py
|
||||
@echo "*** Running yamllint ***"
|
||||
./tests/lint-playbooks.sh
|
||||
|
||||
test:
|
||||
@echo "*** Running tests ***"
|
||||
|
5
tests/lint-playbooks.sh
Executable file
5
tests/lint-playbooks.sh
Executable file
@ -0,0 +1,5 @@
|
||||
#!/usr/bin/sh
|
||||
for f in ./share/lifted/providers/*/playbook.yaml; do
|
||||
echo "linting $f"
|
||||
yamllint -c ./tests/yamllint.conf "$f"
|
||||
done
|
1
tests/yamllint.conf
Normal file
1
tests/yamllint.conf
Normal file
@ -0,0 +1 @@
|
||||
line-length: {max: 120, allow-non-breakable-words: true}
|
Loading…
Reference in New Issue
Block a user