[PATCH 6/6] Azure/GitLab CI: Add the pylint checker
Simon Glass
sjg at chromium.org
Mon Nov 22 04:48:41 CET 2021
Add a check that new Python code does not regress the pylint score for
any module.
Signed-off-by: Simon Glass <sjg at chromium.org>
---
.azure-pipelines.yml | 17 +++++++++++++++++
.gitlab-ci.yml | 12 ++++++++++++
2 files changed, 29 insertions(+)
diff --git a/.azure-pipelines.yml b/.azure-pipelines.yml
index 8801ff7d81b..6002477c905 100644
--- a/.azure-pipelines.yml
+++ b/.azure-pipelines.yml
@@ -172,6 +172,23 @@ jobs:
export PATH=/opt/gcc-11.1.0-nolibc/arm-linux-gnueabi/bin:$PATH
test/nokia_rx51_test.sh
+ - job: pylint
+ displayName: Check for any pylint regressions
+ pool:
+ vmImage: $(ubuntu_vm)
+ container:
+ image: $(ci_runner_image)
+ options: $(container_option)
+ steps:
+ - script: |
+ pip install -r test/py/requirements.txt
+ pip install asteval pylint pyopenssl
+ export PATH=${PATH}:~/.local/bin
+ echo "[MASTER]" >> .pylintrc
+ echo "load-plugins=pylint.extensions.docparams" >> .pylintrc
+ pylint --version
+ make pylint
+
- job: test_py
displayName: 'test.py'
pool:
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 4c89daeadcf..226595e04e8 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -180,6 +180,18 @@ Run tests for Nokia RX-51 (aka N900):
- export PATH=/opt/gcc-11.1.0-nolibc/arm-linux-gnueabi/bin:$PATH;
test/nokia_rx51_test.sh
+# Check for any pylint regressions
+Run pylint:
+ stage: testsuites
+ script:
+ - pip install -r test/py/requirements.txt
+ - pip install asteval pylint pyopenssl
+ - export PATH=${PATH}:~/.local/bin
+ - echo "[MASTER]" >> .pylintrc
+ - echo "load-plugins=pylint.extensions.docparams" >> .pylintrc
+ - pylint --version
+ - make pylint
+
# Test sandbox with test.py
sandbox test.py:
variables:
--
2.34.0.rc2.393.gf8c9666880-goog
More information about the U-Boot
mailing list