[py-svn] r63540 - in py/trunk/py/test: plugin testing
hpk at codespeak.net
hpk at codespeak.net
Thu Apr 2 15:33:16 CEST 2009
Author: hpk
Date: Thu Apr 2 15:33:14 2009
New Revision: 63540
Modified:
py/trunk/py/test/plugin/pytest_resultdb.py
py/trunk/py/test/testing/test_config.py
Log:
fixing shallow test bugs
Modified: py/trunk/py/test/plugin/pytest_resultdb.py
==============================================================================
--- py/trunk/py/test/plugin/pytest_resultdb.py (original)
+++ py/trunk/py/test/plugin/pytest_resultdb.py Thu Apr 2 15:33:14 2009
@@ -276,6 +276,9 @@
class TestJSONResultArchive(BaseResultArchiveTests):
cls = JSONResultArchive
+ def setup_method(self, method):
+ py.test.importorskip("simplejson")
+
class TestSQLiteResultArchive(BaseResultArchiveTests):
cls = SQLiteResultArchive
Modified: py/trunk/py/test/testing/test_config.py
==============================================================================
--- py/trunk/py/test/testing/test_config.py (original)
+++ py/trunk/py/test/testing/test_config.py Thu Apr 2 15:33:14 2009
@@ -55,13 +55,9 @@
type="int", dest="gdest", help="g value."),
)
""")
- old = testdir.chdir()
- try:
- py.test.raises(ValueError, """
- py.test.config._reparse(['-g', '17'])
- """)
- finally:
- old.chdir()
+ py.test.raises(ValueError, """
+ py.test.config._reparse(['-g', '17'])
+ """)
def test_parsing_again_fails(self, tmpdir):
config = py.test.config._reparse([tmpdir])
More information about the pytest-commit
mailing list