modernize tox.ini a bit and make another test dict-ordering independent

This commit is contained in:
holger krekel
2014-09-18 19:40:48 +02:00
parent 3a75b754d0
commit 7a0cb35322
2 changed files with 18 additions and 8 deletions

View File

@@ -83,11 +83,10 @@ class TestEachScheduling:
class TestLoadScheduling: class TestLoadScheduling:
def test_schedule_load_simple(self): def test_schedule_load_simple(self):
node1 = MockNode()
node2 = MockNode()
sched = LoadScheduling(2) sched = LoadScheduling(2)
sched.addnode(node1) sched.addnode(MockNode())
sched.addnode(node2) sched.addnode(MockNode())
node1, node2 = sched.nodes
collection = ["a.py::test_1", "a.py::test_2"] collection = ["a.py::test_1", "a.py::test_2"]
assert not sched.collection_is_completed assert not sched.collection_is_completed
sched.addnode_collection(node1, collection) sched.addnode_collection(node1, collection)

19
tox.ini
View File

@@ -1,10 +1,10 @@
[tox] [tox]
envlist=py26,py32,py33,py34,py27,py27-pexpect,py33-pexpect,py26,py26-old,py33-old,flakes envlist=py26,py33,py34,py27,py27-pexpect,py33-pexpect,py26,py26-old,py33-old,flakes
[testenv] [testenv]
changedir=testing changedir=testing
deps=pytest>=2.5.1 deps=pytest>=2.5.1
commands= py.test --junitxml={envlogdir}/junit-{envname}.xml [] commands= py.test {posargs}
[testenv:py27-pexpect] [testenv:py27-pexpect]
deps={[testenv]deps} deps={[testenv]deps}
@@ -19,13 +19,24 @@ deps = pytest-flakes>=0.2
commands = py.test --flakes -m flakes testing xdist commands = py.test --flakes -m flakes testing xdist
[testenv:py26-old] [testenv:py26-old]
basepython = python2.6
deps= deps=
pytest==2.4.2 pytest==2.5.2
pycmd
commands=
py.cleanup -a
py.test {posargs}
[testenv:py33-old] [testenv:py33-old]
basepython = python3.3 basepython = python3.3
deps= deps=
pytest==2.4.2 pytest==2.5.2
pycmd
commands=
py.cleanup -a
py.test {posargs}
[pytest] [pytest]
addopts = -rsfxX addopts = -rsfxX