Fix lint in unit tests re: py3-first and py2 compat
Change-Id: I22d359df04f613c9a3306b8eae5ab9298acc9120
This commit is contained in:
parent
455d0ed358
commit
2a10af39c8
3
.stestr.conf
Normal file
3
.stestr.conf
Normal file
@ -0,0 +1,3 @@
|
||||
[DEFAULT]
|
||||
test_path=./unit_tests
|
||||
top_dir=./
|
@ -24,5 +24,6 @@ def _add_path(path):
|
||||
if path not in sys.path:
|
||||
sys.path.insert(1, path)
|
||||
|
||||
|
||||
_add_path(_actions)
|
||||
_add_path(_hooks)
|
||||
|
@ -150,7 +150,7 @@ def patch_open():
|
||||
|
||||
Yields the mock for "open" and "file", respectively.'''
|
||||
mock_open = MagicMock(spec=open)
|
||||
mock_file = MagicMock(spec=file)
|
||||
mock_file = MagicMock(spec=__file__)
|
||||
|
||||
@contextmanager
|
||||
def stub_open(*args, **kwargs):
|
||||
|
Loading…
x
Reference in New Issue
Block a user