Skip to main content

flake8-vedro

Flake8 based linter for Vedro framework

Installation

pip install flake8-vedro

Configuration

Flake8-vedro is flake8 plugin, so the configuration is the same as flake8 configuration.

You can ignore rules via

  • file setup.cfg: parameter ignore
[flake8]
ignore = VDR101
  • comment in code #noqa: VDR101

Some rules in linter should be configurated:

[flake8]
scenario_params_max_count = 8  # VDR109
allowed_to_redefine_list = page,page2  # VDR311
is_context_assert_optional = true     # VDR400
allowed_interfaces_list = KafkaApi,SmthApi  # VDR302
allow_partial_redefinitions_in_one_step = True # VDR312
allow_unused_with_block_attributes = False  # VDR313
ignore_variables_pattern = ^(log|history).*  # VDR313
allow_ifs_in_steps = init,given  # VDR314

Rules

Scenario Rules

  1. VDR001. Decorator @vedro.only should not be presented
  2. VDR002. Scenario should be inherited from class vedro.Scenario
  3. VDR103. Scenario should be located in the folder "scenarios/”
  4. VDR104. Scenario should have a subject
  5. VDR105. Scenario subject should not be empty
  6. VDR106. Scenario should have only one subject
  7. VDR107. Subject is not parameterized*
  8. VDR108. Calling functions in parametrization
  9. VDR109. Limit the amount of parameters in a parametrized scenario
  10. VDR110. Scenario subject should be unique*

Scenario Steps Rules

  1. VDR300. Step name should start with..
  2. VDR301. Steps name should be in right order
  3. VDR302. Interface should not be used in given or asserted steps
  4. VDR303. Scenario should have a "when" step
  5. VDR304. Scenario should have only one "when" step
  6. VDR305. Scenario should have a "then" step
  7. VDR306. Scenario should have only one "then" step
  8. VDR307. Step should have an assertion
  9. VDR308. Step should have specific assertions
  10. VDR309. Step should not have comparison without assert
  11. VDR310. Some steps should not have an assertion
  12. VDR311. Scope variables should not be redefined
  13. VDR312. Scope variables should not be partially redefined
  14. VDR313. Scope variables should not be left unused
  15. VDR314. Steps should not have branching

Contexts Rules

  1. VDR400. Contexts should have specific assertions

Metadata

Release files for flake8-vedro 1.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for flake8-vedro 1.3.0
File Size Uploaded
flake8_vedro-1.3.0.tar.gz 28.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for flake8-vedro 1.3.0
File Interpreter ABI Platform
flake8_vedro-1.3.0-py3-none-any.whl Python 3 none any Details

Total release size: 64.7 kB

Release files / flake8_vedro-1.3.0.tar.gz

Download URL flake8_vedro-1.3.0.tar.gz
Size 28.5 kB
Tags Source
SHA-256 checksum
How to use checksums
7e8a2a9294df56222e8dfe7839808021ca934dcb6fdf35380f3200d11b03d447
BLAKE2b-256 checksum
How to use checksums
ec39d958cc27349fdd4f9d1ddb463c9628598d7359dcc3abe2a188c1885b9040
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.10.21

Release files / flake8_vedro-1.3.0-py3-none-any.whl

Download URL flake8_vedro-1.3.0-py3-none-any.whl
Size 36.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
0001f68a5330bc8b49d9731d66cf276265a1a643530266bcf60870d4efb0d74d
BLAKE2b-256 checksum
How to use checksums
e1487bdf684fcfcb8bdb6c584e420cf9e86a43c2bdaba5bda4c61f77fbe4e29b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.10.21

Release history Release notifications | RSS feed

This release

1.3.0 This release

2 release files

1.2.0

2 release files

1.1.2

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.3

2 release files

1.0.2

2 release files

1.0.1

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page