Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Add support for venv-based test run with tox.
* Adds tox config - based on the config from python-quantumclient and updated for test, pep8 and coverage execution as per nova's run_tests.sh. * Adds nosetests defaults in setup.cfg * Adds runtime dependencies in tools/pip-requires - dependencies were gathered by referencing the packages used in creation of a Swift All In One. Versions were determined by checking the swift-core/trunk ppa or, failing that, the version available in lucid. * Adds test dependencies in tools/test-requires * Updates swift/common/middleware/formpost.py for pep8 compliance * Adds instructions for executing the tests with Tox to the developer_guidelines * Adds instructions for installing openstack.nose_plugin to developer_saio * Fixes bug 909177 Change-Id: I5407924d2181e9ab335aaf76bf30c8d40deccbb4
- Loading branch information
Maru Newby
committed
Mar 8, 2012
1 parent
ad6684a
commit e6ea310
Showing
11 changed files
with
98 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
#!/bin/bash | ||
|
||
nosetests test/functional --exe $@ | ||
nosetests test/functionalnosetests --exe $@ | ||
nosetests test/functional $@ | ||
nosetests test/functionalnosetests $@ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,3 +6,4 @@ ChangeLog | |
.coverage | ||
swift.egg-info | ||
.DS_Store | ||
.tox |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
#!/bin/bash | ||
|
||
nosetests test/probe --exe | ||
nosetests test/probe |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
#!/bin/bash | ||
|
||
nosetests test/unit --exe --with-coverage --cover-package swift --cover-erase $@ | ||
nosetests test/unit --with-coverage --cover-package swift --cover-erase $@ | ||
rm -f .coverage |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
WebOb==1.0.8 | ||
configobj==4.7.1 | ||
eventlet==0.9.15 | ||
greenlet==0.3.1 | ||
netifaces==0.6 | ||
pastedeploy==1.3.3 | ||
simplejson==2.0.9 | ||
xattr==0.4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
coverage | ||
nose | ||
nosexcover | ||
openstack.nose_plugin | ||
pep8==0.6.1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
[tox] | ||
envlist = py26,py27,pep8 | ||
|
||
[testenv] | ||
deps = | ||
-r{toxinidir}/tools/pip-requires | ||
-r{toxinidir}/tools/test-requires | ||
commands = nosetests test/unit [] | ||
|
||
[testenv:pep8] | ||
deps = pep8==0.6.1 | ||
commands = | ||
pep8 --repeat --show-pep8 --show-source --ignore=W602 swift tools setup.py | ||
|
||
[testenv:cover] | ||
commands = | ||
coverage erase | ||
nosetests test/unit --with-coverage --cover-html --cover-erase \ | ||
--cover-package=swift | ||
/bin/rm -f .coverage | ||
|
||
[testenv:hudson] | ||
downloadcache = ~/cache/pip | ||
|
||
[testenv:jenkins26] | ||
basepython = python2.6 | ||
deps = file://{toxinidir}/.cache.bundle | ||
|
||
[testenv:jenkins27] | ||
basepython = python2.7 | ||
deps = file://{toxinidir}/.cache.bundle | ||
|
||
[testenv:jenkinspep8] | ||
deps = file://{toxinidir}/.cache.bundle | ||
commands = | ||
pep8 --repeat --show-pep8 --show-source --ignore=W602 swift tools setup.py | ||
|
||
[testenv:jenkinscover] | ||
deps = file://{toxinidir}/.cache.bundle | ||
commands = | ||
nosetests test/unit --with-xcoverage --cover-erase --cover-package=swift |