X7ROOT File Manager
Current Path:
/opt/gsutil/third_party/mock/mock/tests
opt
/
gsutil
/
third_party
/
mock
/
mock
/
tests
/
📁
..
📄
__init__.py
(146 B)
📄
__main__.py
(623 B)
📄
support.py
(552 B)
📄
testcallable.py
(4.33 KB)
📄
testhelpers.py
(28.02 KB)
📄
testmagicmethods.py
(16 KB)
📄
testmock.py
(49.29 KB)
📄
testpatch.py
(55.03 KB)
📄
testsentinel.py
(976 B)
📄
testwith.py
(10.34 KB)
Editing: support.py
import sys info = sys.version_info import unittest2 try: callable = callable except NameError: def callable(obj): return hasattr(obj, '__call__') with_available = sys.version_info[:2] >= (2, 5) def is_instance(obj, klass): """Version of is_instance that doesn't access __class__""" return issubclass(type(obj), klass) class SomeClass(object): class_attribute = None def wibble(self): pass class X(object): pass try: next = next except NameError: def next(obj): return obj.next()
Upload File
Create Folder