Added PyPy env to tox.ini

Also fixes tests that were broken on PyPy.

Co-Authored-By: Jim Rollenhagen <jim@jimrollenhagen.com>
Change-Id: I2554aa844b040c4c74cbf287dccb06d816a39dbe
This commit is contained in:
Alex Gaynor 2014-03-27 15:35:16 -07:00 committed by Jim Rollenhagen
parent 6329ae46db
commit a3cab12393
2 changed files with 3 additions and 3 deletions

View File

@ -128,7 +128,7 @@ class GenericHardwareManager(HardwareManager):
def _list_block_devices(self): def _list_block_devices(self):
report = self._cmd(['blockdev', '--report'])[0] report = self._cmd(['blockdev', '--report'])[0]
lines = report.split('\n') lines = report.split('\n')
lines = [line.split() for line in lines if line is not ''] lines = [line.split() for line in lines if line != '']
startsec_idx = lines[0].index('StartSec') startsec_idx = lines[0].index('StartSec')
device_idx = lines[0].index('Device') device_idx = lines[0].index('Device')
size_idx = lines[0].index('Size') size_idx = lines[0].index('Size')

View File

@ -1,7 +1,7 @@
[tox] [tox]
minversion = 1.6 minversion = 1.6
skipsdist = True skipsdist = True
envlist = py26,py27,pep8 envlist = py26,py27,pypy,pep8
[testenv] [testenv]
usedevelop = True usedevelop = True
@ -39,4 +39,4 @@ builtins = _
exclude = .venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,build,*ironic/nova*,tools exclude = .venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,build,*ironic/nova*,tools
[hacking] [hacking]
import_exceptions = ironic.openstack.common.gettextutils._,testtools.matchers import_exceptions = ironic.openstack.common.gettextutils._,testtools.matchers