2010-11-02 07:53:53 +08:00
|
|
|
|
|
|
|
|
2011-07-09 18:02:22 +08:00
|
|
|
Welcome to pytest!
|
2011-07-07 04:05:48 +08:00
|
|
|
=============================================
|
2010-11-06 06:37:31 +08:00
|
|
|
|
2011-07-07 04:05:48 +08:00
|
|
|
- **a mature full-featured testing tool**
|
2008-08-16 23:26:59 +08:00
|
|
|
|
2011-08-20 01:25:52 +08:00
|
|
|
- runs on Posix/Windows, Python 2.4-3.2, PyPy and Jython-2.5.1
|
2011-07-09 19:23:58 +08:00
|
|
|
- :ref:`comprehensive online <toc>` and `PDF documentation <pytest.pdf>`_
|
2011-07-07 04:05:48 +08:00
|
|
|
- continuously `tested on many Python interpreters <http://hudson.testrun.org/view/pytest/job/pytest/>`_
|
|
|
|
- used in :ref:`many projects and organisations <projects>`, in test
|
|
|
|
suites ranging from 10 to 10s of thousands of tests
|
2011-07-08 18:42:26 +08:00
|
|
|
- comes with many :ref:`tested examples <examples>`
|
2011-07-07 04:05:48 +08:00
|
|
|
- supports :ref:`good integration practises <goodpractises>`
|
2008-08-16 23:26:59 +08:00
|
|
|
|
2011-07-07 04:05:48 +08:00
|
|
|
- **provides no-boilerplate testing**
|
|
|
|
|
|
|
|
- makes it :ref:`easy to get started <getstarted>`,
|
|
|
|
- refined :ref:`usage options <usage>`
|
|
|
|
- :ref:`assert with the assert statement`
|
|
|
|
- helpful :ref:`traceback and failing assertion reporting <tbreportdemo>`
|
|
|
|
- allows :ref:`print debugging <printdebugging>` and :ref:`the
|
|
|
|
capturing of standard output during test execution <captures>`
|
|
|
|
- supports :pep:`8` compliant coding styles in tests
|
|
|
|
|
|
|
|
- **supports functional testing and complex test setups**
|
|
|
|
|
2011-11-09 01:20:56 +08:00
|
|
|
- (new in 2.2) :ref:`durations`
|
2011-11-12 07:02:06 +08:00
|
|
|
- (much improved in 2.2) :ref:`marking and test selection <mark>`
|
2011-11-19 02:32:11 +08:00
|
|
|
- (improved in 2.2) :ref:`parametrized test functions <parametrized test functions>`
|
2011-07-07 04:05:48 +08:00
|
|
|
- advanced :ref:`skip and xfail`
|
2011-11-19 02:32:11 +08:00
|
|
|
- unique :ref:`dependency injection through funcargs <funcargs>`
|
2011-07-07 04:05:48 +08:00
|
|
|
- can :ref:`distribute tests to multiple CPUs <xdistcpu>` through :ref:`xdist plugin <xdist>`
|
|
|
|
- can :ref:`continuously re-run failing tests <looponfailing>`
|
|
|
|
- many :ref:`builtin helpers <pytest helpers>`
|
|
|
|
- flexible :ref:`Python test discovery`
|
|
|
|
|
|
|
|
- **integrates many common testing methods**
|
|
|
|
|
|
|
|
- can integrate ``nose``, ``unittest.py`` and ``doctest.py`` style
|
|
|
|
tests, including running testcases made for Django and trial
|
|
|
|
- supports extended :ref:`xUnit style setup <xunitsetup>`
|
|
|
|
- supports domain-specific :ref:`non-python tests`
|
|
|
|
- supports the generation of testing coverage reports
|
|
|
|
- `Javascript unit- and functional testing`_
|
|
|
|
|
|
|
|
- **extensive plugin and customization system**
|
|
|
|
|
|
|
|
- all collection, reporting, running aspects are delegated to hook functions
|
|
|
|
- customizations can be per-directory, per-project or per PyPI released plugins
|
|
|
|
- it is easy to add command line options or do other kind of add-ons and customizations.
|
|
|
|
|
|
|
|
.. _`Javascript unit- and functional testing`: http://pypi.python.org/pypi/oejskit
|
|
|
|
|
|
|
|
.. _`easy`: http://bruynooghe.blogspot.com/2009/12/skipping-slow-test-by-default-in-pytest.html
|
2009-03-24 00:40:18 +08:00
|
|
|
|
2008-08-16 23:26:59 +08:00
|
|
|
|