[svn r62211] merge 60797:HEAD of pytestplugin branch:
this merge contains: * a new plugin architecture * a pluginized pytest core * many pytest related refactorings * refactorings/streamlining of pytest's own tests --HG-- branch : trunk
This commit is contained in:
@@ -2,14 +2,13 @@
|
||||
import py
|
||||
failure_demo = py.magic.autopath().dirpath('failure_demo.py')
|
||||
|
||||
from py.__.test.testing import suptest
|
||||
from py.__.test import event
|
||||
pytest_plugins = "pytest_pytester"
|
||||
|
||||
def test_failure_demo_fails_properly():
|
||||
sorter = suptest.events_from_cmdline([failure_demo])
|
||||
def test_failure_demo_fails_properly(testdir):
|
||||
sorter = testdir.inline_run(failure_demo)
|
||||
passed, skipped, failed = sorter.countoutcomes()
|
||||
assert passed == 0
|
||||
assert failed == 20, failed
|
||||
colreports = sorter.get(event.CollectionReport)
|
||||
colreports = sorter.getnamed("collectionreport")
|
||||
failed = len([x.failed for x in colreports])
|
||||
assert failed == 5
|
||||
|
||||
Reference in New Issue
Block a user