Skip to content

Don't import unittest in debugging.py #13917

@bluetech

Description

@bluetech

In the pytest code we try very hard to avoid importing unittest if it's not already imported, even in the unittest plugin. But we slipped here:

import unittest

We should handle it similarly to other places by checking if unittest is in sys.modules first.

Metadata

Metadata

Assignees

No one assigned

    Labels

    plugin: debuggingrelated to the debugging builtin plugin

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions