diff --git a/testflo/utresult.py b/testflo/utresult.py index ad089c4..767cdff 100644 --- a/testflo/utresult.py +++ b/testflo/utresult.py @@ -76,7 +76,12 @@ def addSuccess(self, test): def addSkip(self, test, reason): """Called when a test is skipped.""" - resdata = self._tests[test.id()] + # as of Python 3.12.1, startTest is not called before processing skips, so we + # add the test to our list without having called the super() startTest method + if test.id() not in self._tests: + resdata = self._tests[test.id()] = _ResultData(test) + else: + resdata = self._tests[test.id()] resdata.status = 'SKIP' resdata.error = reason super().addSkip(test, reason)