[py-svn] pytest commit 57f312d11228: last changes, preparing 2.0.0
commits-noreply at bitbucket.org
commits-noreply at bitbucket.org
Thu Nov 25 20:07:04 CET 2010
# HG changeset patch -- Bitbucket.org
# Project pytest
# URL http://bitbucket.org/hpk42/pytest/overview
# User holger krekel <holger at merlinux.eu>
# Date 1290712002 -3600
# Node ID 57f312d1122860af1b0642541d6082b540322777
# Parent 83cd00f43c899b8754faccf03dd3fafd33992729
last changes, preparing 2.0.0
--- a/testing/test_capture.py
+++ b/testing/test_capture.py
@@ -77,6 +77,7 @@ class TestCaptureManager:
finally:
capouter.reset()
+ at pytest.mark.xfail("hasattr(sys, 'pypy_version_info')")
@pytest.mark.multi(method=['fd', 'sys'])
def test_capturing_unicode(testdir, method):
if sys.version_info >= (3,0):
--- a/doc/assert.txt
+++ b/doc/assert.txt
@@ -84,6 +84,8 @@ asserts that the given ``ExpectedExcepti
provide you with helpful output in case of failures such as *no
exception* or *wrong exception*.
+.. _newreport:
+
Making use of context-sensitive comparisons
-------------------------------------------------
@@ -130,7 +132,7 @@ Special comparisons are done for a numbe
* comparing long sequences: first failing indices
* comparing dicts: different entries
-See the :ref:`reporting demo <reportingdemo>` for examples.
+See the :ref:`reporting demo <tbreportdemo>` for many more examples.
..
Defining your own comparison
--- a/doc/example/reportingdemo.txt
+++ b/doc/example/reportingdemo.txt
@@ -7,7 +7,9 @@ Demo of Python failure reports with py.t
Here is a nice run of several tens of failures
and how py.test presents things (unfortunately
not showing the nice colors here in the HTML that you
-get on the terminal - we are working on that)::
+get on the terminal - we are working on that):
+
+.. code-block:: python
assertion $ py.test failure_demo.py
=========================== test session starts ============================
--- a/pytest.py
+++ b/pytest.py
@@ -1,7 +1,7 @@
"""
unit and functional testing with Python.
"""
-__version__ = '2.0.0.dev42'
+__version__ = '2.0.0'
__all__ = ['main']
from _pytest.core import main, UsageError, _preloadplugins
--- a/setup.py
+++ b/setup.py
@@ -22,7 +22,7 @@ def main():
name='pytest',
description='py.test: simple powerful testing with Python',
long_description = long_description,
- version='2.0.0.dev42',
+ version='2.0.0',
url='http://pytest.org',
license='MIT license',
platforms=['unix', 'linux', 'osx', 'cygwin', 'win32'],
--- a/_pytest/terminal.py
+++ b/_pytest/terminal.py
@@ -257,6 +257,9 @@ class TerminalReporter:
self.write_sep("=", "test session starts", bold=True)
verinfo = ".".join(map(str, sys.version_info[:3]))
msg = "platform %s -- Python %s" % (sys.platform, verinfo)
+ if hasattr(sys, 'pypy_version_info'):
+ verinfo = ".".join(map(str, sys.pypy_version_info[:3]))
+ msg += "[pypy-%s]" % verinfo
msg += " -- pytest-%s" % (py.test.__version__)
if self.verbosity > 0 or self.config.option.debug or \
getattr(self.config.option, 'pastebin', None):
--- a/doc/announce/release-2.0.0.txt
+++ b/doc/announce/release-2.0.0.txt
@@ -41,7 +41,7 @@ New Features
- new and better reporting information in assert expressions
if comparing lists, sequences or strings.
- see http://pytest.org/2.0.0/assert.html for details.
+ see http://pytest.org/2.0.0/assert.html#newreport
- new configuration through ini-files (setup.cfg or tox.ini recognized),
for example::
More information about the pytest-commit
mailing list