Python Test Coverage Tool

The Python Test Coverage tool enables the collection and display of code coverage data on Python software source code bases of arbitrary size. It is a member of SD's family of Test Coverage tools.

Python Test Coverage Features

  • Python2 and Python3 compatible, covering Python 2.1 to Python 3.8
  • Works with arbitrary subsets of source code base
  • Can accumulate data from multiple test runs
  • Handles tens of thousands of files
  • Extremely low probe overhead
  • Complete control over which Python class files are profiled
  • Operations to combine Test Coverage data for unions, deltas, intersections
  • Incremental insertion of probes
  • Incremental reporting of which test cases need to be re-run based on code changes at the method level
  • Produces coverage report by method, class, application, file. The coverage report can be exported as XML. Either summary can be produced in a batch script to enable test coverage in build scripts.
  • The probe installer component runs on Windows
  • Test Coverage data display can run on any platform with a full JVM

The Python Test Coverage tool has an intuitively simply display. It shows

  • Possible test coverage vector (TCV) result files
  • Selected/accumulated/computed TCV files
  • List of files being tested for coverage
  • Locations of probe points in files
  • Browsable source text of file of current interest
  • Covered/uncovered status of each probe point on file source text
  • Summary statistics for percentage covered

Python Test Coverage Display screen shot

Here's a screenshot (in a popup window) of the Python Test Coverage display applied to a system of over 600 Python files (100,000 lines). If you have popups disabled, try this link: screen shot Green ("go") code has been covered/executed by some test; red ("stop") code has not been executed by any test.

Download an evaluation copy

For more information:    Follow us at Twitter: @SemanticDesigns

Test Coverage