* On Python 3, shlex expects Unicode, not bytes: don't encode
* Replace map() with list-comprehension where a list is expected.
* tox.ini: add cinder.tests.unit.test_hitachi_hbsd_horcm_fc to Python 3.4
Blueprint cinder-python3
Change-Id: Id0db0dabef98f7dd8331a5149e88dee0622917b3
cmd = [cmd]
if args:
- if isinstance(args, six.text_type):
+ if six.PY2 and isinstance(args, six.text_type):
cmd += shlex.split(args.encode())
else:
cmd += shlex.split(args)
if not i.isdigit():
msg = basic_lib.output_err(601, param='hitachi_horcm_numbers')
raise exception.HBSDError(message=msg)
- self.conf.hitachi_horcm_numbers = map(int, numbers)
+ self.conf.hitachi_horcm_numbers = [int(num) for num in numbers]
inst = self.conf.hitachi_horcm_numbers[0]
pair_inst = self.conf.hitachi_horcm_numbers[1]
if inst == pair_inst:
cinder.tests.unit.test_evaluator \
cinder.tests.unit.test_exception \
cinder.tests.unit.test_gpfs \
+ cinder.tests.unit.test_hitachi_hbsd_horcm_fc \
cinder.tests.unit.test_hitachi_hbsd_snm2_fc \
cinder.tests.unit.test_hitachi_hbsd_snm2_iscsi \
cinder.tests.unit.test_hp_xp_fc \