Skip to content

Feature request: Access to TestReport object in post_run callback #445

@richjyoung

Description

@richjyoung

It would be nice to have access to the TestReport object within the post_run callback of class vunit.ui.VUnit, as the current Results object only allows for merging coverage reports. This would be useful for programmatically constructing different reports, rather than re-parsing the XML which may or may not have been included in the CLI arguments.

Currently, both the TestReport object for printing to the screen and the Results object for the callback are both constructed in the _main_run function of ui.py, before post_run is invoked with just the Results object.

As Results seems to only be a wrapper to pass to the callback, I propose extending this object to take a second constructor argument of the existing TestReport object within _main_run.

This should not break any existing interfaces, and provided this is an acceptable approach to the project maintainers I am happy to submit a pull request.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions