skillfed

pytest-helpers-namespace

Pytest Helpers Namespace Plugin

pytest-helpers-namespace v2021.12.29 230.6K downloads/30d#9,105 on PyPI58
Permissive license Apache Software License 2.0 Abandoned released

What it is and what it does

pytest-helpers-namespace is a pytest plugin that creates a shared namespace accessible via pytest.helpers, allowing you to register helper functions in conftest.py and call them directly from test files without importing them. This reduces boilerplate in test files and centralizes helper definitions. The plugin supports nested namespaces, so you can organize helpers hierarchically (e.g., pytest.helpers.can.haz.foo).

The package depends only on pytest and installs with low friction. However, it has been abandoned since late 2022 with no active maintenance. The last release was 2021-12-29, meaning it may not be tested or compatible with recent pytest versions or Python releases beyond those listed in its classifiers.

Use it for:

  • Centralize test utilities in conftest.py and access them via pytest.helpers without import statements in every test file.
  • Organize related helper functions into nested namespaces (e.g., pytest.helpers.database.connect) for better code structure.
  • Share common test setup functions across a large test suite without polluting the global namespace or test file imports.
  • Reduce test file boilerplate by making frequently used helper functions available through a single pytest.helpers entry point.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Provides a pytest namespace for registering and accessing helper functions in conftest.py without explicit imports in test files.

Yes, if you are using an older pytest version and your test suite is stable. The plugin is simple, has no external dependencies beyond pytest, and solves a real organizational problem. However, do not use it in new projects or if you need active maintenance—the package is abandoned and may break with future pytest releases. Consider alternatives or inline helpers in conftest.py for new work.

Install

pytest-helpers-namespace on PyPI

pip

pip install pytest-helpers-namespace

uv

uv add pytest-helpers-namespace

poetry

poetry add pytest-helpers-namespace

Installing pytest-helpers-namespace

Before you install

Low friction install with a single runtime dependency (pytest). However, the package is abandoned—last release was 2021-12-29 and last commit 2022-10-10. No active maintenance means bugs or compatibility issues with newer pytest versions will not be addressed.

License in practice

Licensed under Apache Software License 2.0, a permissive open-source license. You may use, modify, and distribute this package freely in commercial or private projects with minimal restrictions.

Quickstart

pip install pytest-helpers-namespace

# In conftest.py:
import pytest

@pytest.helpers.register
def my_helper(value):
    return value

# In test file:
def test_example():
    assert pytest.helpers.my_helper(True) is True

Verify before relying

  • Compatibility with pytest versions released after 2022-10-10 is unknown and untested.
  • Whether nested helper namespaces (pytest.helpers.can.haz) work reliably with current pytest is unverified.

Package facts

License Apache Software License 2.0 (permissive)
Python support supports the current Python release (>=3.5.6)
Install friction low — pure-Python wheel
Runtime dependencies 1 — pytest
Maintenance abandoned — 1,689 days since the last release
Last repo commit
First released
Downloads 230,571/month — #9,105 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: pytest_helpers_namespace-2021.12.29-py3-none-any.whl

Development Status :: 5 - Production/StableIntended Audience :: DevelopersLicense :: OSI Approved :: Apache Software LicenseProgramming Language :: CythonProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.5Programming Language :: Python :: 3.6Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9

Tags

pytest helper functions namespacepytest conftest helperspytest shared test utilitiespytest plugin helperspytest test fixtures helpers
pytest-plugintest-helpersabandoned

More Testing packages

pluggy

Pluggy provides a plugin system that lets you…

permissive · top 100 on PyPI

pytest

pytest is a testing framework that lets you…

permissive · top 100 on PyPI

virtualenv

virtualenv creates isolated Python environments…

permissive · top 100 on PyPI

coverage

Coverage.py measures which lines of Python code…

permissive · top 1,000 on PyPI

pytest-asyncio

pytest-asyncio is a pytest plugin that enables…

permissive · top 1,000 on PyPI

pytest-json-ctrf

A pytest plugin that generates test reports in…

permissive · top 1,000 on PyPI

pytest-datafiles

A pytest plugin that copies specified files and…

permissive · top 15,000 on PyPI

pytest-logging

A pytest plugin that configures Python logging…

permissive · top 15,000 on PyPI

pytest-socket

A pytest plugin that blocks or restricts socket…

permissive · top 5,000 on PyPI

pytest-xml

A pytest plugin that generates XML output from…

unclear · top 15,000 on PyPI

pytest-cython

A pytest plugin that runs doctests embedded in…

unclear · top 15,000 on PyPI

pytest-find-dependencies

A pytest plugin that identifies dependencies…

permissive · top 5,000 on PyPI

pytest-error-for-skips

A pytest plugin that converts skipped tests…

permissive · top 15,000 on PyPI

apipkg

apipkg lets you define a package's exported…

permissive · top 5,000 on PyPI

pytest-variables

A pytest plugin that loads test variables from…

copyleft · top 15,000 on PyPI

pytest-astropy-header

A pytest plugin that automatically includes…

permissive · top 15,000 on PyPI