diff --git a/testplan/testing/base.py b/testplan/testing/base.py index 91bfb913c..7412daeb1 100644 --- a/testplan/testing/base.py +++ b/testplan/testing/base.py @@ -694,6 +694,7 @@ def _run_resource_hook( testcase_name=hook_name, testcase_report=case_report, ) + case_report.pass_if_empty() try: interface.check_signature(hook, ["env", "result"]) hook_args = (runtime_env, case_result) @@ -709,7 +710,6 @@ def _run_resource_hook( if self.get_stdout_style(case_report.passed).display_testcase: self.log_testcase_status(case_report) - case_report.pass_if_empty() pattern = ":".join([self.name, suite_name, hook_name]) self._xfail(pattern, case_report) case_report.runtime_status = RuntimeStatus.FINISHED