]> git-server-git.apps.pok.os.sepia.ceph.com Git - teuthology.git/commitdiff
task.tests: Update pytest_runtest_makereport
authorZack Cerza <zack@redhat.com>
Thu, 31 Mar 2022 20:29:16 +0000 (16:29 -0400)
committerZack Cerza <zack@redhat.com>
Tue, 19 Apr 2022 21:31:07 +0000 (15:31 -0600)
And fix a typo

Signed-off-by: Zack Cerza <zack@redhat.com>
teuthology/task/tests/__init__.py

index c066f666000c48de217661c11e6e395def01dbce..43c6c11699178f56efe509541b9acf42cdef3c36 100644 (file)
@@ -44,10 +44,12 @@ class TeuthologyContextPlugin(object):
             metafunc.parametrize(["ctx", "config"], [(self.ctx, self.config),])
 
     # log the outcome of each test
-    def pytest_runtest_makereport(self, __multicall__, item, call):
-        report = __multicall__.execute()
+    @pytest.hookimpl(hookwrapper=True)
+    def pytest_runtest_makereport(self, item, call):
+        outcome = yield
+        report = outcome.get_result()
 
-        # after the test has been called, get it's report and log it
+        # after the test has been called, get its report and log it
         if call.when == 'call':
             # item.location[0] is a slash delimeted path to the test file
             # being ran. We only want the portion after teuthology.task.tests