Skip to content

Commit

Permalink
Fix #45 deprecated __multicall__ parameter (#52)
Browse files Browse the repository at this point in the history
  • Loading branch information
lukas-bednar authored Oct 18, 2016
1 parent 8c5c082 commit f6a1d2d
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions pytest_jira.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,13 +53,14 @@ def is_issue_resolved(self, issue_id):
else:
return not self.is_affected(issue_id)

@pytest.mark.tryfirst
def pytest_runtest_makereport(self, item, call, __multicall__):
@pytest.hookimpl(hookwrapper=True)
def pytest_runtest_makereport(self, item, call):
'''
Figure out how to mark JIRA test other than SKIPPED
'''

rep = __multicall__.execute()
outcome = yield
rep = outcome.get_result()
try:
jira_ids = self.mark.get_jira_issues(item)
except Exception:
Expand All @@ -75,8 +76,6 @@ def pytest_runtest_makereport(self, item, call, __multicall__):
rep.wasxfail = "failed"
break

return rep

def pytest_runtest_setup(self, item):
"""
Skip test if ...
Expand Down

0 comments on commit f6a1d2d

Please sign in to comment.