Commit 968b02f8 authored by Aymeric Augustin's avatar Aymeric Augustin
Browse files

Refs #20461 -- Made tblib optional for a passing test run.

This was the original intent.
parent c97b755a
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
@@ -171,6 +171,13 @@ failure and get a correct traceback.
        self.events.append(('addSkip', self.test_index, reason))

    def addExpectedFailure(self, test, err):
        # If tblib isn't installed, pickling the traceback will always fail.
        # However we don't want tblib to be required for running the tests
        # when they pass or fail as expected. Drop the traceback when an
        # expected failure occurs.
        if tblib is None:
            err = err[0], err[1], None
        else:
            self.check_pickleable(test, err)
        self.events.append(('addExpectedFailure', self.test_index, err))