Skip to main content

Pytest plugin that shows a real-time test dashboard in a local web server

Project description

pytest-liveview

A pytest plugin that shows a real-time test dashboard in a local web server. Watch your tests run live as they execute.

Features

  • Real-time updates via Server-Sent Events
  • Summary counts: running, passed, failed, skipped
  • Expandable test suites with per-suite counts
  • Expandable tests with captured output (stdout, stderr, tracebacks)
  • Text filter by test/suite name (flexible, space-separated)
  • Status filter: all, running, passed, failed, skipped, pending
  • Configurable port (default 8085, tries next if busy)
  • Optional browser launch via --liveview-open flag

Installation

pip install pytest-liveview

Usage

Run pytest with the --liveview flag:

pytest --liveview

The dashboard URL is printed to stderr and shown in the pytest header, e.g.:

liveview: http://127.0.0.1:8085

To open the browser automatically:

pytest --liveview --liveview-open

Options

Option Description
--liveview Enable the liveview dashboard
--liveview-port PORT Use a specific port (default: 8085)
--liveview-open Open browser automatically

Troubleshooting

  • No output in expanded tests: Don't use -s (which disables capture). Output is captured by default.
  • Dashboard not updating / stats stuck on "running": This happens with pytest-xdist (-n 2 or parallel mode). Workers run in separate processes, so updates never reach the dashboard. The plugin auto-disables parallel execution when liveview is enabled. If you use addopts = -n 2 in config, run without it: pytest --liveview (the plugin overrides it).

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pytest_liveview-0.1.0.tar.gz (14.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pytest_liveview-0.1.0-py3-none-any.whl (13.0 kB view details)

Uploaded Python 3

File details

Details for the file pytest_liveview-0.1.0.tar.gz.

File metadata

  • Download URL: pytest_liveview-0.1.0.tar.gz
  • Upload date:
  • Size: 14.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.5

File hashes

Hashes for pytest_liveview-0.1.0.tar.gz
Algorithm Hash digest
SHA256 37e7f8418da8bd5dea899a3d54c5b9aa5db1f7852d2c93ba42a030c44e84f578
MD5 c65830e3e0fe0d438913fe67fd150a19
BLAKE2b-256 4e70509d47cac85a101900e385fb8c63526215808c2eb18fd6a9d64f389a15cd

See more details on using hashes here.

File details

Details for the file pytest_liveview-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for pytest_liveview-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 30b4f68928446ca8c842e0cd541244eb2c74a178e8b57b9d768910704b19c166
MD5 951d0226b93c29a800f41587bb24fb00
BLAKE2b-256 922590a95077cc176da1830df308d193ba8937a065f50415caac2a68970bd48c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page