Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inject pytest.item into registered additional_information_callback calls #50

Closed
casabre opened this issue Jun 4, 2024 · 0 comments · Fixed by #51
Closed

Inject pytest.item into registered additional_information_callback calls #50

casabre opened this issue Jun 4, 2024 · 0 comments · Fixed by #51

Comments

@casabre
Copy link
Member

casabre commented Jun 4, 2024

I want to retrieve more information from the testcase in order to build my additional data in any registered hook stage, e.g.

@additional_information_callback("pytest_runtest_logreport")
def more_data(item: pytest.Item) -> dict:
    return {"name": item.nodeid}

For sessions stages, it would be useful to input the session information.

@casabre casabre linked a pull request Jun 4, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant