Fix tests and drop Python 2.6 support

This commit is contained in:
Dmitry Tantsur 2014-10-13 14:06:45 +02:00
parent 54361e70d7
commit 25a9ba6d38
4 changed files with 4 additions and 5 deletions

View File

@ -2,7 +2,6 @@ language: python
python: 2.7 python: 2.7
env: env:
- TOX_ENV=py27 - TOX_ENV=py27
- TOX_ENV=py26
- TOX_ENV=py33 - TOX_ENV=py33
- TOX_ENV=flake8 - TOX_ENV=flake8
install: install:

View File

@ -95,7 +95,7 @@ Next checkout and create environments::
tox tox
Repeat *tox* command each time you need to run tests. If you don't have Python Repeat *tox* command each time you need to run tests. If you don't have Python
interpreter of one of supported versions (currently 2.6, 2.7 and 3.3), use interpreter of one of supported versions (currently 2.7 and 3.3), use
``-e`` flag to select only some environments, e.g. ``-e`` flag to select only some environments, e.g.
:: ::

View File

@ -146,7 +146,7 @@ class TestClient(unittest.TestCase):
client.discover(['uuid1', 'uuid2'], client.discover(['uuid1', 'uuid2'],
auth_token="token") auth_token="token")
mock_post.assert_called_once_with( mock_post.assert_called_once_with(
"http://127.0.0.1:5000/v1/discover", "http://127.0.0.1:5050/v1/discover",
data='["uuid1", "uuid2"]', data='["uuid1", "uuid2"]',
headers={'Content-Type': 'application/json', headers={'Content-Type': 'application/json',
'X-Auth-Token': 'token'} 'X-Auth-Token': 'token'}

View File

@ -1,5 +1,5 @@
[tox] [tox]
envlist = py26,py27,py33,flake8 envlist = py27,py33,flake8
[testenv] [testenv]
usedevelop = True usedevelop = True
@ -15,4 +15,4 @@ deps =
-rrequirements.txt -rrequirements.txt
flake8 flake8
commands = commands =
flake8 ironic_discoverd flake8 ironic_discoverd