skillfed

pytest-split-tests

A Pytest plugin for running a subset of your tests by splitting them in to equally sized groups. Forked from Mark Adams' original project pytest-test-groups.

pytest-split-tests v1.1.0 80.8K downloads/30d#14,267 on PyPI7
Permissive license DORMANT released

What it is and what it does

pytest-split-tests is a pytest plugin that partitions your test suite into equally-sized groups and lets you run a specific group. It's designed to solve the problem of long-running test jobs in CI by allowing you to distribute test execution across parallel workers—each worker runs a different group, reducing total wall-clock time.

The plugin adds command-line flags to pytest: --test-group-count sets the number of groups, --test-group selects which group to run, and --test-group-random-seed optionally assigns tests pseudo-randomly instead of sequentially. It depends only on pytest, making it lightweight to add to existing test infrastructure.

Use it for:

  • Distribute a large test suite across multiple CI workers to reduce build time.
  • Run a specific subset of tests locally for faster feedback during development.
  • Balance test load across parallel jobs when test execution time varies widely.
  • Integrate into CI pipelines (GitHub Actions, GitLab CI, etc.) to parallelize test stages.

Worth the install?

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

A pytest plugin that splits your test suite into equal-sized groups so you can run a specific group in parallel or distributed CI environments.

Yes, if you need to parallelize tests in CI and are comfortable with dormant maintenance. The plugin is simple, has no known vulnerabilities, and low install friction. However, be aware that it has not been updated since 2021 and may not work reliably with pytest or Python versions released after that date—verify compatibility with your environment before relying on it in production.

Install

pytest-split-tests on PyPI

pip

pip install pytest-split-tests

uv

uv add pytest-split-tests

poetry

poetry add pytest-split-tests

Installing pytest-split-tests

Before you install

Low install friction; depends only on pytest. Maintenance is dormant—last release was 2021-07-30 and no commits since 2024-07-30—so expect no active bug fixes or feature updates, though the package remains archived=false.

License in practice

MIT license (permissive); you can use, modify, and distribute this package freely with minimal restrictions.

Quickstart

pip install pytest-split-tests

# In your CI or local shell:
py.test --test-group-count 10 --test-group=2

Verify before relying

  • Whether the plugin works with pytest versions released after 2021-07-30 without issues.
  • Compatibility with modern Python versions beyond 3.9 (classifiers list only up to 3.9).

Package facts

License not declared (permissive)
Python support not specified
Install friction low — pure-Python wheel
Runtime dependencies 1 — pytest
Maintenance dormant — 1,841 days since the last release
Last repo commit
First released
Downloads 80,818/month — #14,267 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: pytest_split_tests-1.1.0-py2.py3-none-any.whl

Development Status :: 5 - Production/StableIntended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseOperating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 3.6Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9Topic :: Software Development :: Testing

Tags

pytest parallel test groupssplit tests into groupspytest distributed testingci test parallelizationpytest subset runnertest group splitting
ci-parallelizationpytest-plugin

More Testing packages