Created
May 19, 2017 00:40
-
-
Save Kalimaha/91366d4eda1aeed2e69829c19b296e6a to your computer and use it in GitHub Desktop.
Local PyTest Plugin
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import pytest | |
| from pytest_pact.utils.pytest_utils import read_marker | |
| @pytest.hookimpl(hookwrapper=True) | |
| def pytest_pyfunc_call(pyfuncitem): | |
| state = read_marker(pyfuncitem, 'state') | |
| print(state) | |
| outcome = yield | |
| res = outcome.get_result() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment