# pytest-dev/pytest-bdd

BDD library for the pytest runner

Repository: https://github.com/pytest-dev/pytest-bdd
Canonical: https://ross.abutalabs.com/products/pytest-bdd
Homepage: https://pytest-bdd.readthedocs.io/en/latest/
Language: Python
License: MIT
License Family: permissive
Topics: bdd, bdd-framework, pytest-plugin, python, python3, testing
Last push: 2026-08-24T21:29:53+00:00

## Health v2 (maintenance only)
Score: 77/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 99, release rhythm 35, longevity 100
- inputs: {"age_days": 4905, "days_push": 9, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1461, forks 248 (observed 2026-08-28T04:04:47.432361+00:00)

## What it is
pytest-bdd is a pytest plugin that implements a subset of the Gherkin language for behavior-driven development (BDD). It lets you write feature files and bind Gherkin steps to pytest fixtures and test functions without needing a separate test runner.

## Use cases
- write BDD-style acceptance tests in Gherkin with pytest
- reuse pytest fixtures as BDD step definitions via dependency injection
- automate project requirements testing from feature files
- unify unit and functional tests in one pytest run
- run Cucumber-style scenarios without a separate BDD runner

## When to choose
- your team already uses pytest and wants BDD syntax
- you want to share fixtures and setup between unit and BDD tests
- you prefer Gherkin feature files for stakeholder-readable specs

## When to avoid
- you need full Gherkin/Cucumber compatibility rather than a subset
- your project does not use pytest
- you need a standalone BDD runner independent of pytest

## Facets
- artifact type: library
- maturity: active
- function: testing, e2e-testing
- domain: testing, developer-tools
- platform: python, cli, cross-platform
- tags: bdd, pytest-plugin, gherkin, behavior-driven-development, test-automation

## Member repositories
- pytest-dev/pytest-bdd (main) score 77

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:04:47.432361+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T04:35:22.026209+00:00, confidence not recorded.
  - readme: https://github.com/pytest-dev/pytest-bdd (fetched 2026-08-28T04:04:47.432361+00:00, sha 725ff59360e2)
  - registry_pypi: https://pypi.org/pypi/pytest-bdd/json (fetched 2026-08-29T11:44:28.659374+00:00, sha c03577e5f13b)
- Data as of 2026-08-30T08:39:29.467469+00:00.
