From 3e574189c7011719d145e9037f2478ccf259c6ae Mon Sep 17 00:00:00 2001 From: Ivan Schaller Date: Mon, 20 Jun 2022 14:31:41 +0200 Subject: [PATCH] add isort and mypy test --- .woodpecker/tests.yml | 20 +++++++++++++++++--- README.md | 13 +++++++++++++ 2 files changed, 30 insertions(+), 3 deletions(-) diff --git a/.woodpecker/tests.yml b/.woodpecker/tests.yml index 60a55bc..8c8ca20 100644 --- a/.woodpecker/tests.yml +++ b/.woodpecker/tests.yml @@ -10,19 +10,33 @@ clone: pipeline: - # check shell scripts with shfmt + # check code style - shell test-shfmt: image: 'cr.44net.ch/drone-plugins/test' pull: true commands: - shfmt -d -i 4 -bn -ci -sr . - # check python scripts with black + # check code style - python test-black: image: 'cr.44net.ch/drone-plugins/test' pull: true commands: - - black --check --diff --color . + - black --check --diff . + + # check imports - python + test-isort: + image: 'cr.44net.ch/drone-plugins/test' + pull: true + commands: + - isort --check-only --diff . + + # check static typing - python + test-mypy: + image: 'cr.44net.ch/drone-plugins/test' + pull: true + commands: + - mypy --install-types --non-interactive --show-error-context --show-column-numbers --show-error-codes mangadlp/ # test code and generate coverage report test-coverage-pytest: diff --git a/README.md b/README.md index 4a879a6..988566d 100644 --- a/README.md +++ b/README.md @@ -2,11 +2,24 @@ ## python script to download mangas +#### CI/CD: + [![status-badge](https://ci.44net.ch/api/badges/olofvndrhr/manga-dlp/status.svg)](https://ci.44net.ch/olofvndrhr/manga-dlp) + +#### Code Analysis: + [![Quality Gate Status](https://sonarqube.44net.ch/api/project_badges/measure?project=olofvndrhr%3Amanga-dlp&metric=alert_status&token=f9558470580eea5b4899cf33f190eee16011346d)](https://sonarqube.44net.ch/dashboard?id=olofvndrhr%3Amanga-dlp) [![Coverage](https://sonarqube.44net.ch/api/project_badges/measure?project=olofvndrhr%3Amanga-dlp&metric=coverage&token=f9558470580eea5b4899cf33f190eee16011346d)](https://sonarqube.44net.ch/dashboard?id=olofvndrhr%3Amanga-dlp) [![Bugs](https://sonarqube.44net.ch/api/project_badges/measure?project=olofvndrhr%3Amanga-dlp&metric=bugs&token=f9558470580eea5b4899cf33f190eee16011346d)](https://sonarqube.44net.ch/dashboard?id=olofvndrhr%3Amanga-dlp) + +#### Meta: + [![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black) +[![types - Mypy](https://img.shields.io/badge/types-Mypy-blue.svg)](https://github.com/python/mypy) +[![imports - isort](https://img.shields.io/badge/imports-isort-ef8336.svg)](https://github.com/pycqa/isort) +[![License - MIT](https://img.shields.io/badge/license-MIT-9400d3.svg)](https://snyk.io/learn/what-is-mit-license/) + +--- ## Description