Fix Python 3 issues in Windows tests
* Replace __builtin__ with six.moves.builtins * tox.ini: add the following tests to Python 3.4 - cinder.tests.unit.windows.test_smbfs - cinder.tests.unit.windows.test_vhdutils - cinder.tests.unit.windows.test_windows - cinder.tests.unit.windows.test_windows_remotefs - cinder.tests.unit.windows.test_windows_utils This change requires the Python 3 fixes in os-brick. Blueprint cinder-python3 Change-Id: I1ffa65745923459e993e81d8a95a39e19c1bd1e4
This commit is contained in:
parent
742026723c
commit
4055078083
@ -55,7 +55,7 @@ class WindowsSmbFsTestCase(test.TestCase):
|
||||
|
||||
mock.patch('sys.platform', 'win32').start()
|
||||
mock.patch.dict(sys.modules, ctypes=mock.DEFAULT).start()
|
||||
mock.patch('__builtin__.wmi', create=True).start()
|
||||
mock.patch('six.moves.builtins.wmi', create=True).start()
|
||||
|
||||
self.addCleanup(mock.patch.stopall)
|
||||
|
||||
|
7
tox.ini
7
tox.ini
@ -99,7 +99,12 @@ commands =
|
||||
cinder.tests.unit.test_volume_types \
|
||||
cinder.tests.unit.test_volume_types_extra_specs \
|
||||
cinder.tests.unit.test_volume_utils \
|
||||
cinder.tests.unit.volume.flows.test_create_volume_flow
|
||||
cinder.tests.unit.volume.flows.test_create_volume_flow \
|
||||
cinder.tests.unit.windows.test_smbfs \
|
||||
cinder.tests.unit.windows.test_vhdutils \
|
||||
cinder.tests.unit.windows.test_windows \
|
||||
cinder.tests.unit.windows.test_windows_remotefs \
|
||||
cinder.tests.unit.windows.test_windows_utils
|
||||
|
||||
[testenv:pep8]
|
||||
commands =
|
||||
|
Loading…
x
Reference in New Issue
Block a user