Skip to main content
Python Software Foundation 20th Year Anniversary Fundraiser  Donate today!

pytest plugin to display test execution output like a mochajs

Project description


Pytest output in MochaJS format


It uses docstrigs as a tool to create the sections that mocha creates using the describe and it structure. Example:

# file examples/
def test_case():
    '''Section :: subsection :: Should execute test'''

outputs this:

Section :: examples/
        ✓ Should execute test


pip install pytest-mocha


pytest --mocha


  • --mocha: Enable mocha as pytest reporter
  • --mocha-force-disable: Disable mocha reporter even if enabled with --mocha flag

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 pytest-mocha, version 0.4.0
Filename, size File type Python version Upload date Hashes
Filename, size pytest_mocha-0.4.0-py2.py3-none-any.whl (5.5 kB) File type Wheel Python version py2.py3 Upload date Hashes View
Filename, size pytest-mocha-0.4.0.tar.gz (3.7 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