[py-svn] py-trunk commit d70d85a54bb0: updating some feature descriptions
commits-noreply at bitbucket.org
commits-noreply at bitbucket.org
Mon Jul 26 13:17:47 CEST 2010
# HG changeset patch -- Bitbucket.org
# Project py-trunk
# URL http://bitbucket.org/hpk42/py-trunk/overview
# User holger krekel <holger at merlinux.eu>
# Date 1278612819 -7200
# Node ID d70d85a54bb0c3965b2f6c3071e213af83bf0aa0
# Parent 9a17cd126ba186bda5fdf01fc1bd58f8e58ab75e
updating some feature descriptions
--- a/doc/test/features.txt
+++ b/doc/test/features.txt
@@ -82,7 +82,7 @@ filename are inspected for finding tests
* classes with a leading ``Test`` name and ``test`` prefixed methods.
* ``unittest.TestCase`` subclasses
-parametrizing test functions and advanced functional testing
+parametrizing test functions and functional testing
--------------------------------------------------------------
py.test offers the unique `funcargs mechanism`_ for setting up
@@ -177,32 +177,32 @@ test functions. You can modify tracebac
command line. Using the `--pdb`` option you can automatically activate
a PDB `Python debugger`_ when a test fails.
-advanced skipping of tests
+skip or expect-to-fail a test
======================================
-py.test has `advanced support for skipping tests`_ or expecting
-failures on tests on certain platforms. Apart from the
-minimal py.test style also unittest- and nose-style tests
-can make use of this feature.
+py.test has a dedicated `skipping plugin`_ that allows to define
-.. _`advanced support for skipping tests`: plugin/skipping.html
+* define "skip" outcomes indicating a platform or a
+ dependency mismatch.
+
+* "xfail" outcomes indicating an "expected failure" either with
+ with or without running a test.
+
+* skip and xfail outcomes can be applied at module, class or method
+ level or even only for certain argument sets of a parametrized function.
+
+.. _`skipping plugin`: plugin/skipping.html
.. _`funcargs mechanism`: funcargs.html
.. _`unittest.py`: http://docs.python.org/library/unittest.html
.. _`doctest.py`: http://docs.python.org/library/doctest.html
.. _`xUnit style setup`: xunit_setup.html
.. _`pytest_nose`: plugin/nose.html
-advanced test selection and running modes
+select tests by keyword / test name search
=========================================================
.. _`selection by keyword`:
-``py.test --looponfailing`` (implemented through the external
-`pytest-xdist`_ plugin) allows to run a test suite,
-memorize all failures and then loop over the failing set
-of tests until they all pass. It will re-start running
-the tests when it detects file changes in your project.
-
You can selectively run tests by specifiying a keyword
on the command line. Examples::
@@ -236,6 +236,15 @@ plugin for more information.
.. _`pytest_keyword`: plugin/mark.html
+Looping on the failing test set
+=======================================
+
+``py.test --looponfailing`` (implemented through the external
+`pytest-xdist`_ plugin) allows to run a test suite,
+memorize all failures and then loop over the failing set
+of tests until they all pass. It will re-start running
+the tests when it detects file changes in your project.
+
.. _`reStructured Text`: http://docutils.sourceforge.net
.. _`Python debugger`: http://docs.python.org/lib/module-pdb.html
More information about the pytest-commit
mailing list