flake8 based linter for e2e tests
Project description
flake8-qa-style
Flake8 based linter with some qa best-practice for writing tests
Installation
pip inslall flake8-qa-style
Rules
- CS001: using sleep(1) instead of sleep(var), var - meaningful variable
- CS002: using print()
- CS003: assert same variables: assert var == var
- CS004: assert variable with constant: assert var == 1
- CS005: missing type annotation for argument in function
- CS006: missing function return type annotation
- CS007: file should not start with a blank line
- CS008: nested "with" statements of the same type should be comma-separated
Rules configuration
[flake8]
;for methods with @property decorator skip CS006
skip_property_return_annotation = true
Configuration
Flake8-qa-style is flake8 plugin, so the configuration is the same as flake8 configuration.
You can ignore rules via
- file
setup.cfg: parameterignore
[flake8]
ignore = CS001
- comment in code
#noqa: CS001
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
flake8_qa_style-1.1.0.tar.gz
(13.2 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file flake8_qa_style-1.1.0.tar.gz.
File metadata
- Download URL: flake8_qa_style-1.1.0.tar.gz
- Upload date:
- Size: 13.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.15
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2fab062e30a3c82a7fa2e5e7951df6962f14b176a0a45168fc846305d464928e
|
|
| MD5 |
ac9efa5aa70f8d005eca4e4d8b50c51d
|
|
| BLAKE2b-256 |
be89a769de3eee568b7984c8c670a42b10bd48510d54d186a79ed7468b6062b8
|
File details
Details for the file flake8_qa_style-1.1.0-py3-none-any.whl.
File metadata
- Download URL: flake8_qa_style-1.1.0-py3-none-any.whl
- Upload date:
- Size: 18.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.15
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9bc4c1cbda44165fd8373dc662bc45c783861b51896f56a1871ad246add678c8
|
|
| MD5 |
1cb021f13f9901d2a6a1f436fc45437e
|
|
| BLAKE2b-256 |
8ee87ff11396212b17386aa399dbf79329cef7d79aa6df870592196dd08fd9c1
|