Skip to content

Alias _Call class? #71

Closed
Closed
@blueyed

Description

@blueyed

I am/was using code like the following to detect if some object is a _Call instance (to stop recursion in this case):

    from pytest_mock import mock_module

    try:
        _Call = mock_module.mock._Call
    except AttributeError:
        # unittest.mock
        _Call = mock_module._Call
    if isinstance(exp, _Call):
        ...

Since mock_module has been moved in a4cfee7, I wonder what is the best way to fix / address this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions