Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions .github/workflows/checks.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
---
name: static-analysis
on: push
jobs:
static-analysis:
name: Static Analysis
runs-on: ubuntu-latest
container: python:3.12
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 2
- name: install prerequisites
run: |
pip install .[check] .[test] black pylint
- name: run black
run: |
black --check --diff .
- name: run pylint
run: |
pylint --fail-under 10 src
pylint --fail-under 10 --disable=protected-access tests
- name: run tests
run: |
pytest . --cov-report lcov
- uses: qltysh/qlty-action/coverage@main
with:
token: ${{secrets.QLTY_COVERAGE_TOKEN}}
files: coverage.lcov
13 changes: 11 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ requires = ["setuptools>=61.0", "build", "setuptools-git-versioning"]
build-backend = "setuptools.build_meta"

[project.optional-dependencies]
test = ["pytest", "pytest-cov", "pytest-asyncio", "pytest-xdist", "ruamel.yaml", "dotted_dict"]
test = ["pytest", "pytest-cov", "pytest-asyncio", "pytest-xdist", "ruamel.yaml", "dotted_dict", "black", "pylint"]

[tool.setuptools.packages.find]
where = ["src"]
Expand All @@ -40,4 +40,13 @@ log_cli = "true"
testpaths = ["tests"]
pythonpath = "src"
addopts = "-n 4 -Walways --cov=cli_wrapper --cov-branch --cov-report html:coverage"
asyncio_default_fixture_loop_scope = "function"
asyncio_default_fixture_loop_scope = "function"

[tool.pylint."messages control"]
disable = [
"missing-module-docstring",
"missing-class-docstring",
"missing-function-docstring",
"logging-fstring-interpolation",
"fixme"
]
4 changes: 4 additions & 0 deletions src/cli_wrapper/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1,5 @@
from .cli_wrapper import CLIWrapper
from .transformers import transformers
from .parsers import parsers

__all__ = ["CLIWrapper", "transformers", "parsers"]
Loading
Loading