Skip to main content

A pygments lexer for pytest output.

Project description

Build Status Coverage Status


A pygments lexer for pytest output

See some demos! Or see it in action on


pip install pygments-pytest


This library provides a pygments lexer called pytest.

.. code-block:: pytest

    $ pytest
    ========================== test session starts ===========================
    platform linux -- Python 3.6.6, pytest-4.0.1.dev43+g0d529847.d20181123, py-1.7.0, pluggy-0.8.0
    rootdir: /home/asottile/workspace/pytest, inifile: tox.ini
    collected 1 item .                                                          [100%]

    ======================== 1 passed in 0.01 seconds ========================

This library also provides a sphinx extension. It can be enabled by adding 'pygments_pytest' to the extensions setting in your

The colors can be tweaked using the sphinx setting (in pygments_pytest_ansi_colors:

pygments_pytest_ansi_colors = {
    'Cyan': '#06989a',
    'Green': '#4e9a06',
    'Red': '#c00',
    'Yellow': '#c4A000',

Project details

Download files

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

Files for pygments-pytest, version 1.2.0
Filename, size File type Python version Upload date Hashes
Filename, size pygments_pytest-1.2.0-py2.py3-none-any.whl (4.4 kB) File type Wheel Python version py2.py3 Upload date Hashes View
Filename, size pygments_pytest-1.2.0.tar.gz (3.1 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page