behave
behave is behaviour-driven development, Python style
Decision gist · record as of 2026-08-14
Yes. behave is actively maintained, has no known vulnerabilities, carries permissive licensing, and low install friction. It's a mature choice (Production/Stable status since 2011) for teams that want BDD-style acceptance testing with readable, collaborative test scenarios. Install it if your workflow involves non-technical stakeholders in test design or if you want executable specifications written in natural language.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires a features/ directory structure with .feature files (Gherkin syntax) and a steps/ subdirectory containing Python step definitions to function.
- Low install friction with a pure-Python wheel distribution.
- The package is actively maintained with recent commits and carries 15 runtime dependencies including parsing libraries (parse, parse-type, cucumber-expressions) and compatibility shims (six, pathlib2, enum34) to support older Python versions.
License · maintenance · safety
BSD-2-Clause (permissive) — Licensed under BSD-2-Clause (permissive), which allows free use, modification, and distribution with minimal restrictions—suitable for both open-source and commercial projects.
last release 2025-09-04 (344 days) · last repo commit 2026-08-14 · 3,523 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 5,950,549 downloads/mo, #2,004 on PyPI
Alternatives
Verify before relying
pip install behave
# Create features/example.feature with Gherkin scenarios
# Create features/steps/example_steps.py with step implementations
from behave import given, when, then
@given('a precondition')
def step_impl(context):
pass
# Run: behave- Whether the 15 runtime dependencies (including older Python compatibility shims like enum34, pathlib2) are all actively maintained or if some are legacy holdovers.
- Performance characteristics or scalability limits when running large numbers of scenarios or steps.
What it is and what it does
behave is a Python implementation of behavior-driven development that bridges the gap between business requirements and test automation. It uses Gherkin—a plain-English syntax for writing test scenarios—paired with Python step implementations to create executable specifications that both technical and non-technical stakeholders can understand and collaborate on.
The framework reads .feature files containing human-readable scenarios (Given-When-Then format), maps each step to Python functions you write, and executes them as tests. It's designed for acceptance testing and cross-team communication rather than unit testing, making it useful when you need to document and validate business behavior in a format that bridges development and QA.
Use it for
- Write acceptance tests in plain English that product managers and QA can read and verify without reading Python code.
- Document system behavior as executable specifications that stay in sync with actual functionality.
- Automate end-to-end workflows where each step represents a user action or system state change.
- Enable non-technical stakeholders to contribute test scenarios by writing Gherkin without touching Python.
- Build a shared test suite that developers, QA, and business analysts can collaborate on and maintain together.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
behave is actively maintained, has no known vulnerabilities, carries permissive licensing, and low install friction. It's a mature choice (Production/Stable status since 2011) for teams that want BDD-style acceptance testing with readable, collaborative test scenarios. Install it if your workflow involves non-technical stakeholders in test design or if you want executable specifications written in natural language.
Install
behave on PyPI
Before you install
Low install friction with a pure-Python wheel distribution. The package is actively maintained with recent commits and carries 15 runtime dependencies including parsing libraries (parse, parse-type, cucumber-expressions) and compatibility shims (six, pathlib2, enum34) to support older Python versions.
Requires a features/ directory structure with .feature files (Gherkin syntax) and a steps/ subdirectory containing Python step definitions to function.
License in practice
Licensed under BSD-2-Clause (permissive), which allows free use, modification, and distribution with minimal restrictions—suitable for both open-source and commercial projects.
Quickstart
pip install behave
# Create features/example.feature with Gherkin scenarios
# Create features/steps/example_steps.py with step implementations
from behave import given, when, then
@given('a precondition')
def step_impl(context):
pass
# Run: behave
Verify before relying
- Whether the 15 runtime dependencies (including older Python compatibility shims like enum34, pathlib2) are all actively maintained or if some are legacy holdovers.
- Performance characteristics or scalability limits when running large numbers of scenarios or steps.
Package facts
| License | BSD-2-Clause permissive |
| Python support | Supports the current Python release !=3.0.*,!=3.1.*,!=3.2.*,>=2.7 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 15 packagescucumber-tag-expressionscucumber-expressionsenum34parseparse-typesixcontextlib2pathlibpathlib2scandirtraceback2win_unicode_consolecoloramatomlitoml |
| Maintenance | Actively maintained 344 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 5,950,549 / month, #2,004 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Development Status :: 5 - Production/StableEnvironment :: ConsoleIntended Audience :: DevelopersOperating System :: OS IndependentProgramming Language :: Python :: 2Programming Language :: Python :: 2.7Programming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.5Programming Language :: Python :: 3.6Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9Programming Language :: Python :: Implementation :: CPythonProgramming Language :: Python :: Implementation :: JythonProgramming Language :: Python :: Implementation :: PyPyTopic :: Software Development :: Testing |
Evidence: behave-1.3.3-py2.py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “Gherkin test scenarios”
- behavebehave is a behavior-driven development (BDD) framework that lets you…
- gherkin-officialParses and compiles Gherkin feature files into abstract syntax trees…
- cucumber-tag-expressionsParses and evaluates boolean tag expressions (using and, or, not…
Give your agent the search over MCP, or paste the wish link into any chat.
More Testing packages
Pluggy provides a plugin system that lets you define hook specifications and register implementations to be called in sequence, enabling extensible Python applications without tight coupling.
Install it if you're building an extensible application or framework.
pytest is a testing framework that lets you write test functions using plain assert statements and automatically discovers and runs them, with detailed failure reporting.
virtualenv creates isolated Python environments where packages can be installed independently without affecting the system Python or other projects.
Coverage.py measures which lines of Python code are executed during test runs, reporting coverage percentages and identifying untested code paths.
Install it if you want to measure test completeness or enforce coverage thresholds in your project.
pytest-asyncio is a pytest plugin that enables writing and running async test functions using the asyncio library, allowing developers to await code directly within test cases.
Install it if you write tests for any asyncio-based code.
A pytest plugin that generates test reports in Common Test Report Format (CTRF) as JSON, compatible with pytest-xdist and pytest-playwright for distributed and browser-based testing.
Install it if you need CTRF-formatted test output for CI/CD integration or cross-tool reporting.
See also behave-django · behavex · pytest-bdd · radish-bdd · cucumber-tag-expressions · cucumber-expressions · terraform-compliance · vedro · behave-html-formatter · gherkin-official