mirror of
https://github.com/Crocmagnon/charasheet.git
synced 2024-11-22 14:38:03 +01:00
70 lines
1.9 KiB
TOML
70 lines
1.9 KiB
TOML
###############################################################################
|
|
# pytest
|
|
###############################################################################
|
|
[tool.pytest.ini_options]
|
|
addopts = """
|
|
--html=test_reports/pytest_result/pytest.html --color=yes --durations 20
|
|
--no-cov-on-fail --strict-markers
|
|
--driver=Firefox
|
|
-W error
|
|
-W "ignore:capabilities and desired_capabilities have been deprecated:DeprecationWarning:pytest_selenium.pytest_selenium"
|
|
-W "ignore:service_log_path has been deprecated:DeprecationWarning:pytest_selenium.pytest_selenium"
|
|
"""
|
|
markers = []
|
|
minversion = "6.0"
|
|
DJANGO_SETTINGS_MODULE = "charasheet.settings"
|
|
junit_family = "xunit1"
|
|
norecursedirs = [
|
|
".*",
|
|
"docker",
|
|
"documentation",
|
|
"static",
|
|
"public",
|
|
]
|
|
testpaths = [
|
|
"src",
|
|
]
|
|
python_files = [
|
|
"test_*.py",
|
|
"tests.py",
|
|
]
|
|
|
|
###############################################################################
|
|
# flake8 / flakeheaven
|
|
###############################################################################
|
|
[tool.flakeheaven]
|
|
max_complexity = 10
|
|
format = "grouped"
|
|
|
|
# Base rules
|
|
#############################
|
|
[tool.flakeheaven.plugins]
|
|
"*" = [
|
|
"+*",
|
|
"-E501", # long lines
|
|
"-E203", # conflict with black on PEP8 interpretation
|
|
"-W503", # deprecated rule: https://www.flake8rules.com/rules/W503.html
|
|
]
|
|
flake8-builtins = [
|
|
"+*",
|
|
"-A003", # class attribute is shadowing a python builtin
|
|
]
|
|
flake8-docstrings = [
|
|
"+*",
|
|
"-D1??", # missing docstring
|
|
]
|
|
flake8-bandit = [
|
|
"+*",
|
|
"-S308", # Use of mark_safe() may expose cross-site scripting vulnerabilities and should be reviewed.
|
|
"-S703", # Potential XSS on mark_safe function.
|
|
]
|
|
|
|
# Exceptions
|
|
#############################
|
|
[tool.flakeheaven.exceptions."**/tests/*"]
|
|
flake8-bandit = [
|
|
"+*",
|
|
"-S101", # Use of assert detected.
|
|
"-S106", # Possible hardcoded password.
|
|
"-S311", # Standard pseudo-random generators are not suitable for security/cryptographic purposes.
|
|
]
|