Add misc types for mock and unittest.mock (#3923)

This commit is contained in:
Max R
2020-04-24 02:51:34 -04:00
committed by GitHub
parent 92f52a2615
commit 31705fca7a
3 changed files with 38 additions and 2 deletions

View File

@@ -5,6 +5,25 @@ from typing import Any, List, Optional, Text, Tuple, Type, TypeVar
_T = TypeVar("_T")
__all__ = [
'Mock',
'MagicMock',
'patch',
'sentinel',
'DEFAULT',
'ANY',
'call',
'create_autospec',
'AsyncMock',
'FILTER_DIR',
'NonCallableMock',
'NonCallableMagicMock',
'mock_open',
'PropertyMock',
'seal',
]
__version__: str
FILTER_DIR: Any
class _slotted: ...

View File

@@ -149,8 +149,6 @@ types.WrapperDescriptorType.__get__
unittest.TestCase.addCleanup
unittest.case.TestCase.addCleanup
unittest.doModuleCleanups
unittest.mock.MagicProxy.__call__
unittest.mock._MockIter.__iter__
weakref.WeakValueDictionary.__init__
weakref.WeakValueDictionary.update
weakref.getweakrefcount

View File

@@ -5,6 +5,25 @@ from typing import Any, List, Optional, Text, Tuple, Type, TypeVar
_T = TypeVar("_T")
__all__ = [
'Mock',
'MagicMock',
'patch',
'sentinel',
'DEFAULT',
'ANY',
'call',
'create_autospec',
'AsyncMock',
'FILTER_DIR',
'NonCallableMock',
'NonCallableMagicMock',
'mock_open',
'PropertyMock',
'seal',
]
__version__: str
FILTER_DIR: Any
class _slotted: ...