Versions follow Semantic Versioning (<major>.<minor>.<patch>).
Backward incompatible (breaking) changes will only be introduced in major versions with advance notice in the Deprecations section of releases.
#6334: Fix summary entries appearing twice when f/F and s/S report chars were used at the same time in the -r command-line option (for example -rFf).
The upper case variants were never documented and the preferred form should be the lower case.
#7310: Fix UnboundLocalError: local variable 'letter' referenced before assignment in _pytest.terminal.pytest_report_teststatus() when plugins return report objects in an unconventional state.
This was making pytest_report_teststatus() skip entering if-block branches that declare the letter variable.
The fix was to set the initial value of the letter before the if-block cascade so that it always has a value.
#6870: New Config.invocation_args attribute containing the unchanged arguments passed to pytest.main().
Remark: while this is technically a new feature and according to our policy it should not have been backported, we have opened an exception in this particular case because it fixes a serious interaction with pytest-xdist, so it can also be considered a bugfix.
The 4.6.X series will be the last series to support Python 2 and Python 3.4.
For more details, see our Python 2.7 and 3.4 support plan.
#4826: A warning is now emitted when unknown marks are used as a decorator. This is often due to a typo, which can lead to silently broken tests.
#4907: Show XFail reason as part of JUnitXML message field.
#5013: Messages from crash reports are displayed within test summaries now, truncated to the terminal width.
#5023: New flag --strict-markers that triggers an error when unknown markers (e.g. those not registered using the markers option in the configuration file) are used in the test suite.
The existing --strict option has the same behavior currently, but can be augmented in the future for additional checks.
#5026: Assertion failure messages for sequences and dicts contain the number of different items now.
#5034: Improve reporting with --lf and --ff (run-last-failure).
#5035: The --cache-show option/action accepts an optional glob to show only matching cache entries.
#5059: Standard input (stdin) can be given to pytester's Testdir.run() and Testdir.popen().
#5068: The -r option learnt about A to display all reports (including passed ones) in the short test summary.
#5108: The short test summary is displayed after passes with output (-rP).
#5172: The --last-failed (--lf) option got smarter and will now skip entire files if all tests of that test file have passed in previous runs, greatly speeding up collection.
#5177: Introduce new specific warning PytestWarning subclasses to make it easier to filter warnings based on the class, rather than on the message. The new subclasses are:
#5202: New record_testsuite_property session-scoped fixture allows users to log <property> tags at the testsuite level with the junitxml plugin.
The generated XML is compatible with the latest xunit standard, contrary to the properties recorded by record_property and record_xml_attribute.
#5214: The default logging format has been changed to improve readability. Here is an example of a previous logging message:
test_log_cli_enabled_disabled.py 3 CRITICAL critical message logged by test
This has now become:
CRITICAL root:test_log_cli_enabled_disabled.py:3 critical message logged by test
The formatting can be changed through the log_format configuration option.
#5220: --fixtures now also shows fixture scope for scopes other than "function".
#2224: async test functions are skipped and a warning is emitted when a suitable async plugin is not installed (such as pytest-asyncio or pytest-trio).
Previously async functions would not execute at all but still be marked as "passed".
#2482: Include new disable_test_id_escaping_and_forfeit_all_rights_to_community_support option to disable ascii-escaping in parametrized values. This may cause a series of problems and as the name makes clear, use at your own risk.
#4718: The -p option can now be used to early-load plugins also by entry-point name, instead of just by module name.
This makes it possible to early load external plugins like pytest-cov in the command-line:
pytest -p pytest_cov
#4855: The --pdbcls option handles classes via module attributes now (e.g. pdb:pdb.Pdb with pdb++), and its validation was improved.
#4875: The testpaths configuration option is now displayed next to the rootdir and inifile lines in the pytest header if the option is in effect, i.e., directories or file names were not explicitly passed in the command line.
Also, inifile is only displayed if there's a configuration file, instead of an empty inifile: string.
#4911: Doctests can be skipped now dynamically using pytest.skip().
#4920: Internal refactorings have been made in order to make the implementation of the pytest-subtests plugin possible, which adds unittest sub-test support and a new subtests fixture as discussed in #1367.
For details on the internal refactorings, please see the details on the related PR.
#4931: pytester's LineMatcher asserts that the passed lines are a sequence.
#4936: Handle -p plug after -p no:plug.
This can be used to override a blocked plugin (e.g. in "addopts") from the command line etc.
#4951: Output capturing is handled correctly when only capturing via fixtures (capsys, capfs) with pdb.set_trace().
#4956: pytester sets $HOME and $USERPROFILE to the temporary directory during test runs.
This ensures to not load configuration files from the real user's home directory.
#4980: Namespace packages are handled better with monkeypatch.syspath_prepend and testdir.syspathinsert (via pkg_resources.fixup_namespace_packages).
#4993: The stepwise plugin reports status information now.
#5008: If a setup.cfg file contains [tool:pytest] and also the no longer supported [pytest] section, pytest will use [tool:pytest] ignoring [pytest]. Previously it would unconditionally error out.
This makes it simpler for plugins to support old pytest versions.
#1895: Fix bug where fixtures requested dynamically via request.getfixturevalue() might be teardown before the requesting fixture.
#4851: pytester unsets PYTEST_ADDOPTS now to not use outer options with testdir.runpytest().
#4903: Use the correct modified time for years after 2038 in rewritten .pyc files.
#4928: Fix line offsets with ScopeMismatch errors.
#4957: -p no:plugin is handled correctly for default (internal) plugins now, e.g. with -p no:capture.
Previously they were loaded (imported) always, making e.g. the capfd fixture available.
#4968: The pdb quit command is handled properly when used after the debug command with pdb++.
#4975: Fix the interpretation of -qq option where it was being considered as -v instead.
#4978: outcomes.Exit is not swallowed in assertrepr_compare anymore.
#4988: Close logging's file handler explicitly when the session finishes.
#5003: Fix line offset with mark collection error (off by one).
#4718: pluggy>=0.9 is now required.
#4815: funcsigs>=1.0 is now required for Python 2.7.
#4829: Some left-over internal code related to yield tests has been removed.
#4890: Remove internally unused anypython fixture from the pytester plugin.
#4912: Remove deprecated Sphinx directive, add_description_unit(), pin sphinx-removed-in to >= 0.2.0 to support Sphinx 2.0.
#4913: Fix pytest tests invocation with custom PYTHONPATH.
#4965: New pytest_report_to_serializable and pytest_report_from_serializable experimental hooks.
These hooks will be used by pytest-xdist, pytest-subtests, and the replacement for resultlog to serialize and customize reports.
They are experimental, meaning that their details might change or even be removed completely in future patch releases without warning.
Feedback is welcome from plugin authors and users alike.
#4987: Collector.repr_failure respects the --tb option, but only defaults to short now (with auto).
#4724: pytest.warns() now emits a warning when it receives unknown keyword arguments.
This will be changed into an error in the future.
#2753: Usage errors from argparse are mapped to pytest's UsageError.
#3711: Add the --ignore-glob parameter to exclude test-modules with Unix shell-style wildcards. Add the collect_ignore_glob for conftest.py to exclude test-modules with Unix shell-style wildcards.
#4698: The warning about Python 2.7 and 3.4 not being supported in pytest 5.0 has been removed.
In the end it was considered to be more of a nuisance than actual utility and users of those Python versions shouldn't have problems as pip will not install pytest 5.0 on those interpreters.
#4707: With the help of new set_log_path() method there is a way to set log_file paths from hooks.
#3094: Classic xunit-style functions and methods now obey the scope of autouse fixtures.
This fixes a number of surprising issues like setup_method being called before session-scoped autouse fixtures (see #517 for an example).
#4627: Display a message at the end of the test session when running under Python 2.7 and 3.4 that pytest 5.0 will no longer support those Python versions.
#4660: The number of selected tests now are also displayed when the -k or -m flags are used.
#4688: pytest_report_teststatus hook now can also receive a config parameter.
#4691: pytest_terminal_summary hook now can also receive a config parameter.
#3547: --junitxml can emit XML compatible with Jenkins xUnit. junit_family INI option accepts legacy|xunit1, which produces old style output, and xunit2 that conforms more strictly to https://github.com/jenkinsci/xunit-plugin/blob/xunit-2.3.2/src/main/resources/org/jenkinsci/plugins/xunit/types/model/xsd/junit-10.xsd
#4280: Improve quitting from pdb, especially with --trace.
Using q[quit] after pdb.set_trace() will quit pytest also.
#4402: Warning summary now groups warnings by message instead of by test id.
This makes the output more compact and better conveys the general idea of how much code is actually generating warnings, instead of how many tests call that code.
#4536: monkeypatch.delattr handles class descriptors like staticmethod/classmethod.
#4649: Restore marks being considered keywords for keyword expressions.
#4653: tmp_path fixture and other related ones provides resolved path (a.k.a real path)
#4667: pytest_terminal_summary uses result from pytest_report_teststatus hook, rather than hardcoded strings.
#4669: Correctly handle unittest.SkipTest exception containing non-ascii characters on Python 2.
#4680: Ensure the tmpdir and the tmp_path fixtures are the same folder.
#4681: Ensure tmp_path is always a real path.
#4643: Use a.item() instead of the deprecated np.asscalar(a) in pytest.approx.
np.asscalar has been deprecated in numpy 1.16..
#4657: Copy saferepr from pylib
#4668: The verbose word for expected failures in the teststatus report changes from xfail to XFAIL to be consistent with other test outcomes.
#2169: pytest.mark.parametrize: in previous versions, errors raised by id functions were suppressed and changed into warnings. Now the exceptions are propagated, along with a pytest message informing the node, parameter value and index where the exception occurred.
#3078: Remove legacy internal warnings system: config.warn, Node.warn. The pytest_logwarning now issues a warning when implemented.
See our docs on information on how to update your code.
#3079: Removed support for yield tests - they are fundamentally broken because they don't support fixtures properly since collection and test execution were separated.
See our docs on information on how to update your code.
#3082: Removed support for applying marks directly to values in @pytest.mark.parametrize. Use pytest.param instead.
See our docs on information on how to update your code.
#3083: Removed Metafunc.addcall. This was the predecessor mechanism to @pytest.mark.parametrize.
See our docs on information on how to update your code.
#3085: Removed support for passing strings to pytest.main. Now, always pass a list of strings instead.
See our docs on information on how to update your code.
#3086: [pytest] section in setup.cfg files is no longer supported, use [tool:pytest] instead. setup.cfg files are meant for use with distutils, and a section named pytest has notoriously been a source of conflicts and bugs.
Note that for pytest.ini and tox.ini files the section remains [pytest].
#3616: Removed the deprecated compat properties for node.Class/Function/Module - use pytest.Class/Function/Module now.
See our docs on information on how to update your code.
#4421: Removed the implementation of the pytest_namespace hook.
See our docs on information on how to update your code.
#4489: Removed request.cached_setup. This was the predecessor mechanism to modern fixtures.
See our docs on information on how to update your code.
#4535: Removed the deprecated PyCollector.makeitem method. This method was made public by mistake a long time ago.
#4543: Removed support to define fixtures using the pytest_funcarg__ prefix. Use the @pytest.fixture decorator instead.
See our docs on information on how to update your code.
#4545: Calling fixtures directly is now always an error instead of a warning.
See our docs on information on how to update your code.
#4546: Remove Node.get_marker(name) the return value was not usable for more than a existence check.
Use Node.get_closest_marker(name) as a replacement.
#4547: The deprecated record_xml_property fixture has been removed, use the more generic record_property instead.
See our docs for more information.
#4548: An error is now raised if the pytest_plugins variable is defined in a non-top-level conftest.py file (i.e., not residing in the rootdir).
See our docs for more information.
#891: Remove testfunction.markername attributes - use Node.iter_markers(name=None) to iterate them.
#3050: Deprecated the pytest.config global.
See https://docs.pytest.org/en/latest/deprecations.html#pytest-config-global for rationale.
#3974: Passing the message parameter of pytest.raises now issues a DeprecationWarning.
It is a common mistake to think this parameter will match the exception message, while in fact it only serves to provide a custom message in case the pytest.raises check fails. To avoid this mistake and because it is believed to be little used, pytest is deprecating it without providing an alternative for the moment.
If you have concerns about this, please comment on issue #3974.
#4435: Deprecated raises(..., 'code(as_a_string)') and warns(..., 'code(as_a_string)').
See https://docs.pytest.org/en/latest/deprecations.html#raises-warns-exec for rationale and examples.
#3191: A warning is now issued when assertions are made for None.
This is a common source of confusion among new users, which write:
assert mocked_object.assert_called_with(3, 4, 5, key="value")
When they should write:
mocked_object.assert_called_with(3, 4, 5, key="value")
Because the assert_called_with method of mock objects already executes an assertion.
This warning will not be issued when None is explicitly checked. An assertion like:
assert variable is None
will not issue the warning.
#3632: Richer equality comparison introspection on AssertionError for objects created using attrs or dataclasses (Python 3.7+, backported to 3.6).
#4278: CACHEDIR.TAG files are now created inside cache directories.
Those files are part of the Cache Directory Tagging Standard, and can be used by backup or synchronization programs to identify pytest's cache directory as such.
#4292: pytest.outcomes.Exit is derived from SystemExit instead of KeyboardInterrupt. This allows us to better handle pdb exiting.
#4371: Updated the --collect-only option to display test descriptions when ran using --verbose.
#4386: Restructured ExceptionInfo object construction and ensure incomplete instances have a repr/str.
#4416: pdb: added support for keyword arguments with pdb.set_trace.
It handles header similar to Python 3.7 does it, and forwards any other keyword arguments to the Pdb constructor.
This allows for __import__("pdb").set_trace(skip=["foo.*"]).
#4483: Added ini parameter junit_duration_report to optionally report test call durations, excluding setup and teardown times.
The JUnit XML specification and the default pytest behavior is to include setup and teardown times in the test duration report. You can include just the call durations instead (excluding setup and teardown) by adding this to your pytest.ini file:
[pytest] junit_duration_report = call
#4532: -ra now will show errors and failures last, instead of as the first items in the summary.
This makes it easier to obtain a list of errors and failures to run tests selectively.
#4599: pytest.importorskip now supports a reason parameter, which will be shown when the requested module cannot be imported.
#4447: Changed the deprecation type of --result-log to PytestDeprecationWarning.
It was decided to remove this feature at the next major revision.
#3737: RemovedInPytest4Warnings are now errors by default.
Following our plan to remove deprecated features with as little disruption as possible, all warnings of type RemovedInPytest4Warnings now generate errors instead of warning messages.
The affected features will be effectively removed in pytest 4.1, so please consult the Deprecations and Removals section in the docs for directions on how to update existing code.
In the pytest 4.0.X series, it is possible to change the errors back into warnings as a stop gap measure by adding this to your pytest.ini file:
[pytest] filterwarnings = ignore::pytest.RemovedInPytest4Warning
But this will stop working when pytest 4.1 is released.
If you have concerns about the removal of a specific feature, please add a comment to #4348.
#4358: Remove the ::() notation to denote a test class instance in node ids.
Previously, node ids that contain test instances would use ::() to denote the instance like this:
test_foo.py::Test::()::test_bar
The extra ::() was puzzling to most users and has been removed, so that the test id becomes now:
test_foo.py::Test::test_bar
This change could not accompany a deprecation period as is usual when user-facing functionality changes because it was not really possible to detect when the functionality was being used explicitly.
The extra ::() might have been removed in some places internally already, which then led to confusion in places where it was expected, e.g. with --deselect (#4127).
Test class instances are also not listed with --collect-only anymore.
#4270: The cache_dir option uses $TOX_ENV_DIR as prefix (if set in the environment).
This uses a different cache per tox environment by default.
#2619: Resume capturing output after continue with __import__("pdb").set_trace().
This also adds a new pytest_leave_pdb hook, and passes in pdb to the existing pytest_enter_pdb hook.
#4147: Add --sw, --stepwise as an alternative to --lf -x for stopping at the first failure, but starting the next test invocation from that test. See the documentation for more info.
#4188: Make --color emit colorful dots when not running in verbose mode. Earlier, it would only colorize the test-by-test output if --verbose was also passed.
#4225: Improve performance with collection reporting in non-quiet mode with terminals.
The "collecting …" message is only printed/updated every 0.5s.
#4272: Display cachedir also in non-verbose mode if non-default.
#4277: pdb: improve message about output capturing with set_trace.
Do not display "IO-capturing turned off/on" when -s is used to avoid confusion.
#4279: Improve message and stack level of warnings issued by monkeypatch.setenv when the value of the environment variable is not a str.
#3616: The following accesses have been documented as deprecated for years, but are now actually emitting deprecation warnings.
Access of Module, Function, Class, Instance, File and Item through Node instances. Now users will this warning:
usage of Function.Module is deprecated, please use pytest.Module instead
Users should just import pytest and access those objects using the pytest module.
request.cached_setup, this was the precursor of the setup/teardown mechanism available to fixtures. You can consult funcarg comparison section in the docs.
Using objects named "Class" as a way to customize the type of nodes that are collected in Collector subclasses has been deprecated. Users instead should use pytest_collect_make_item to customize node types during collection.
This issue should affect only advanced plugins who create new collection types, so if you see this warning message please contact the authors so they can change the code.
The warning that produces the message below has changed to RemovedInPytest4Warning:
getfuncargvalue is deprecated, use getfixturevalue
#3988: Add a Deprecation warning for pytest.ensuretemp as it was deprecated since a while.
#2293: Improve usage errors messages by hiding internal details which can be distracting and noisy.
This has the side effect that some error conditions that previously raised generic errors (such as ValueError for unregistered marks) are now raising Failed exceptions.
#3332: Improve the error displayed when a conftest.py file could not be imported.
In order to implement this, a new chain parameter was added to ExceptionInfo.getrepr to show or hide chained tracebacks in Python 3 (defaults to True).
#3849: Add empty_parameter_set_mark=fail_at_collect ini option for raising an exception when parametrize collects an empty set.
#3964: Log messages generated in the collection phase are shown when live-logging is enabled and/or when they are logged to a file.
#3985: Introduce tmp_path as a fixture providing a Path object.
#4013: Deprecation warnings are now shown even if you customize the warnings filters yourself. In the previous version any customization would override pytest's filters and deprecation warnings would fall back to being hidden by default.
#4073: Allow specification of timeout for Testdir.runpytest_subprocess() and Testdir.run().
#4098: Add returncode argument to pytest.exit() to exit pytest with a specific return code.
#4102: Reimplement pytest.deprecated_call using pytest.warns so it supports the match='...' keyword argument.
This has the side effect that pytest.deprecated_call now raises pytest.fail.Exception instead of AssertionError.
#4149: Require setuptools>=30.3 and move most of the metadata to setup.cfg.
#2535: Improve error message when test functions of unittest.TestCase subclasses use a parametrized fixture.
#3057: request.fixturenames now correctly returns the name of fixtures created by request.getfixturevalue().
#3946: Warning filters passed as command line options using -W now take precedence over filters defined in ini configuration files.
#4066: Fix source reindenting by using textwrap.dedent directly.
#4102: pytest.warn will capture previously-warned warnings in Python 2. Previously they were never raised.
#4108: Resolve symbolic links for args.
This fixes running pytest tests/test_foo.py::test_bar, where tests is a symlink to project/app/tests: previously project/app/conftest.py would be ignored for fixtures then.
#4132: Fix duplicate printing of internal errors when using --pdb.
#4135: pathlib based tmpdir cleanup now correctly handles symlinks in the folder.
#4152: Display the filename when encountering SyntaxWarning.
#4036: The item parameter of pytest_warning_captured hook is now documented as deprecated. We realized only after the 3.8 release that this parameter is incompatible with pytest-xdist.
Our policy is to not deprecate features during bugfix releases, but in this case we believe it makes sense as we are only documenting it as deprecated, without issuing warnings which might potentially break test suites. This will get the word out that hook implementers should not use this parameter at all.
In a future release item will always be None and will emit a proper warning when a hook implementation makes use of it.
#3539: Fix reload on assertion rewritten modules.
#4034: The .user_properties attribute of TestReport objects is a list of (name, value) tuples, but could sometimes be instantiated as a tuple of tuples. It is now always a list.
#4039: No longer issue warnings about using pytest_plugins in non-top-level directories when using --pyargs: the current --pyargs mechanism is not reliable and might give false negatives.
#4040: Exclude empty reports for passed tests when -rP option is used.
#4051: Improve error message when an invalid Python expression is passed to the -m option.
#4056: MonkeyPatch.setenv and MonkeyPatch.delenv issue a warning if the environment variable name is not str on Python 2.
In Python 2, adding unicode keys to os.environ causes problems with subprocess (and possible other modules), making this a subtle bug specially susceptible when used with from __future__ import unicode_literals.
#3286: .pytest_cache directory is now automatically ignored by Git. Users who would like to contribute a solution for other SCMs please consult/comment on this issue.
#3749: Fix the following error during collection of tests inside packages:
TypeError: object of type 'Package' has no len()
#3941: Fix bug where indirect parametrization would consider the scope of all fixtures used by the test function to determine the parametrization scope, and not only the scope of the fixtures being parametrized.
#3973: Fix crash of the assertion rewriter if a test changed the current working directory without restoring it afterwards.
#3998: Fix issue that prevented some caplog properties (for example record_tuples) from being available when entering the debugger with --pdb.
#3999: Fix UnicodeDecodeError in python2.x when a class returns a non-ascii binary __repr__ in an assertion which also contains non-ascii text.
#2452: Config.warn and Node.warn have been deprecated, see https://docs.pytest.org/en/latest/deprecations.html#config-warn-and-node-warn for rationale and examples.
#3936: @pytest.mark.filterwarnings second parameter is no longer regex-escaped, making it possible to actually use regular expressions to check the warning message.
Note: regex-escaping the match string was an implementation oversight that might break test suites which depend on the old behavior.
#2452: Internal pytest warnings are now issued using the standard warnings module, making it possible to use the standard warnings filters to manage those warnings. This introduces PytestWarning, PytestDeprecationWarning and RemovedInPytest4Warning warning types as part of the public API.
Consult the documentation for more info.
#2908: DeprecationWarning and PendingDeprecationWarning are now shown by default if no other warning filter is configured. This makes pytest more compliant with PEP-0506. See the docs for more info.
#3251: Warnings are now captured and displayed during test collection.
#3784: PYTEST_DISABLE_PLUGIN_AUTOLOAD environment variable disables plugin auto-loading when set.
#3829: Added the count option to console_output_style to enable displaying the progress as a count instead of a percentage.
#3837: Added support for 'xfailed' and 'xpassed' outcomes to the pytester.RunResult.assert_outcomes signature.
The pytest-warnings plugin has been integrated into the core and now pytest automatically captures and displays warnings at the end of the test session.
Warning
This feature may disrupt test suites which apply and treat warnings themselves, and can be disabled in your pytest.ini:
[pytest] addopts = -p no:warnings
See the warnings documentation page for more information.
Thanks @nicoddemus for the PR.
Added junit_suite_name ini option to specify root <testsuite> name for JUnit XML reports (#533).
Added an ini option doctest_encoding to specify which encoding to use for doctest files. Thanks @wheerd for the PR (#2101).
pytest.warns now checks for subclass relationship rather than class equality. Thanks @lesteve for the PR (#2166)
pytest.raises now asserts that the error message matches a text or regex with the match keyword argument. Thanks @Kriechi for the PR.
pytest.param can be used to declare test parameter sets with marks and test ids. Thanks @RonnyPfannschmidt for the PR.
Incompatible changes
A number of incompatible changes were made in this release, with the intent of removing features deprecated for a long time or change existing behaviors in order to make them less surprising/more useful.
Reinterpretation mode has now been removed. Only plain and rewrite mode are available, consequently the --assert=reinterp option is no longer available. This also means files imported from plugins or conftest.py will not benefit from improved assertions by default, you should use pytest.register_assert_rewrite() to explicitly turn on assertion rewriting for those files. Thanks @flub for the PR.
The following deprecated commandline options were removed:
Thanks to @RedBeardCode for the PR (#1664).
ImportErrors in plugins now are a fatal error instead of issuing a pytest warning (#1479). Thanks to @The-Compiler for the PR.
Removed support code for Python 3 versions < 3.3 (#1627).
Removed all py.test-X* entry points. The versioned, suffixed entry points were never documented and a leftover from a pre-virtualenv era. These entry points also created broken entry points in wheels, so removing them also removes a source of confusion for users (#1632). Thanks @obestwalter for the PR.
pytest.skip() now raises an error when used to decorate a test function, as opposed to its original intent (to imperatively skip a test inside a test function). Previously this usage would cause the entire module to be skipped (#607). Thanks @omarkohl for the complete PR (#1519).
Exit tests if a collection error occurs. A poll indicated most users will hit CTRL-C anyway as soon as they see collection errors, so pytest might as well make that the default behavior (#1421). A --continue-on-collection-errors option has been added to restore the previous behaviour. Thanks @olegpidsadnyi and @omarkohl for the complete PR (#1628).
Renamed the pytest pdb module (plugin) into debugging to avoid clashes with the builtin pdb module.
Raise a helpful failure message when requesting a parametrized fixture at runtime, e.g. with request.getfixturevalue. Previously these parameters were simply never defined, so a fixture decorated like @pytest.fixture(params=[0, 1, 2]) only ran once (#460). Thanks to @nikratio for the bug report, @RedBeardCode and @tomviner for the PR.
_pytest.monkeypatch.monkeypatch class has been renamed to _pytest.monkeypatch.MonkeyPatch so it doesn't conflict with the monkeypatch fixture.
--exitfirst / -x can now be overridden by a following --maxfail=N and is just a synonym for --maxfail=1.
New Features
Support nose-style __test__ attribute on methods of classes, including unittest-style Classes. If set to False, the test will not be collected.
New doctest_namespace fixture for injecting names into the namespace in which doctests run. Thanks @milliams for the complete PR (#1428).
New --doctest-report option available to change the output format of diffs when running (failing) doctests (implements #1749). Thanks @hartym for the PR.
New name argument to pytest.fixture decorator which allows a custom name for a fixture (to solve the funcarg-shadowing-fixture problem). Thanks @novas0x2a for the complete PR (#1444).
New approx() function for easily comparing floating-point numbers in tests. Thanks @kalekundert for the complete PR (#1441).
Ability to add global properties in the final xunit output file by accessing the internal junitxml plugin (experimental). Thanks @tareqalayan for the complete PR #1454).
New ExceptionInfo.match() method to match a regular expression on the string representation of an exception (#372). Thanks @omarkohl for the complete PR (#1502).
__tracebackhide__ can now also be set to a callable which then can decide whether to filter the traceback based on the ExceptionInfo object passed to it. Thanks @The-Compiler for the complete PR (#1526).
New pytest_make_parametrize_id(config, val) hook which can be used by plugins to provide friendly strings for custom types. Thanks @palaviv for the PR.
capsys and capfd now have a disabled() context-manager method, which can be used to temporarily disable capture within a test. Thanks @nicoddemus for the PR.
New cli flag --fixtures-per-test: shows which fixtures are being used for each selected test item. Features doc strings of fixtures by default. Can also show where fixtures are defined if combined with -v. Thanks @hackebrot for the PR.
Introduce pytest command as recommended entry point. Note that py.test still works and is not scheduled for removal. Closes proposal #1629. Thanks @obestwalter and @davehunt for the complete PR (#1633).
New cli flags:
Thanks @d6e, @kvas-it, @sallner, @ioggstream and @omarkohl for the PRs.
New CLI flag --override-ini/-o: overrides values from the ini file. For example: "-o xfail_strict=True"'. Thanks @blueyed and @fengxx for the PR.
New hooks:
Issue warnings for asserts whose test is a tuple literal. Such asserts will never fail because tuples are always truthy and are usually a mistake (see #1562). Thanks @kvas-it, for the PR.
Allow passing a custom debugger class (e.g. --pdbcls=IPython.core.debugger:Pdb). Thanks to @anntzer for the PR.
Changes
Bug Fixes
Bug Fixes
Bug Fixes
New Features
Changes
Important: py.code has been merged into the pytest repository as pytest._code. This decision was made because py.code had very few uses outside pytest and the fact that it was in a different repository made it difficult to fix bugs on its code in a timely manner. The team hopes with this to be able to better refactor out and improve that code. This change shouldn't affect users, but it is useful to let users aware if they encounter any strange behavior.
Keep in mind that the code for pytest._code is private and experimental, so you definitely should not import it explicitly!
Please note that the original py.code is still available in pylib.
pytest_enter_pdb now optionally receives the pytest config object. Thanks @nicoddemus for the PR.
Removed code and documentation for Python 2.5 or lower versions, including removal of the obsolete _pytest.assertion.oldinterpret module. Thanks @nicoddemus for the PR (#1226).
Comparisons now always show up in full when CI or BUILD_NUMBER is found in the environment, even when -vv isn't used. Thanks @The-Compiler for the PR.
--lf and --ff now support long names: --last-failed and --failed-first respectively. Thanks @MichaelAquilina for the PR.
Added expected exceptions to pytest.raises fail message.
Collection only displays progress ("collecting X items") when in a terminal. This avoids cluttering the output when using --color=yes to obtain colors in CI integrations systems (#1397).
Bug Fixes
new --lf and -ff options to run only the last failing tests or "failing tests first" from the last run. This functionality is provided through porting the formerly external pytest-cache plugin into pytest core. BACKWARD INCOMPAT: if you used pytest-cache's functionality to persist data between test runs be aware that we don't serialize sets anymore. Thanks Ronny Pfannschmidt for most of the merging work.
"-r" option now accepts "a" to include all possible reports, similar to passing "fEsxXw" explicitly (isse960). Thanks Abhijeet Kasurde for the PR.
avoid python3.5 deprecation warnings by introducing version specific inspection helpers, thanks Michael Droettboom.
fix issue562: @nose.tools.istest now fully respected.
fix issue934: when string comparison fails and a diff is too large to display without passing -vv, still show a few lines of the diff. Thanks Florian Bruhin for the report and Bruno Oliveira for the PR.
fix issue736: Fix a bug where fixture params would be discarded when combined with parametrization markers. Thanks to Markus Unterwaditzer for the PR.
fix issue710: introduce ALLOW_UNICODE doctest option: when enabled, the u prefix is stripped from unicode strings in expected doctest output. This allows doctests which use unicode to run in Python 2 and 3 unchanged. Thanks Jason R. Coombs for the report and Bruno Oliveira for the PR.
parametrize now also generates meaningful test IDs for enum, regex and class objects (as opposed to class instances). Thanks to Florian Bruhin for the PR.
Add 'warns' to assert that warnings are thrown (like 'raises'). Thanks to Eric Hunsberger for the PR.
Fix issue683: Do not apply an already applied mark. Thanks ojake for the PR.
Deal with capturing failures better so fewer exceptions get lost to /dev/null. Thanks David Szotten for the PR.
fix issue730: deprecate and warn about the --genscript option. Thanks Ronny Pfannschmidt for the report and Christian Pommranz for the PR.
fix issue751: multiple parametrize with ids bug if it parametrizes class with two or more test methods. Thanks Sergey Chipiga for reporting and Jan Bednarik for PR.
fix issue82: avoid loading conftest files from setup.cfg/pytest.ini/tox.ini files and upwards by default (--confcutdir can still be set to override this). Thanks Bruno Oliveira for the PR.
fix issue768: docstrings found in python modules were not setting up session fixtures. Thanks Jason R. Coombs for reporting and Bruno Oliveira for the PR.
added tmpdir_factory, a session-scoped fixture that can be used to create directories under the base temporary directory. Previously this object was installed as a _tmpdirhandler attribute of the config object, but now it is part of the official API and using config._tmpdirhandler is deprecated. Thanks Bruno Oliveira for the PR.
fix issue808: pytest's internal assertion rewrite hook now implements the optional PEP302 get_data API so tests can access data files next to them. Thanks xmo-odoo for request and example and Bruno Oliveira for the PR.
rootdir and inifile are now displayed during usage errors to help users diagnose problems such as unexpected ini files which add unknown options being picked up by pytest. Thanks to Pavel Savchenko for bringing the problem to attention in #821 and Bruno Oliveira for the PR.
Summary bar now is colored yellow for warning situations such as: all tests either were skipped or xpass/xfailed, or no tests were run at all (this is a partial fix for issue500).
fix issue812: pytest now exits with status code 5 in situations where no tests were run at all, such as the directory given in the command line does not contain any tests or as result of a command line option filters all out all tests (-k for example). Thanks Eric Siegerman (issue812) and Bruno Oliveira for the PR.
Summary bar now is colored yellow for warning situations such as: all tests either were skipped or xpass/xfailed, or no tests were run at all (related to issue500). Thanks Eric Siegerman.
New testpaths ini option: list of directories to search for tests when executing pytest from the root directory. This can be used to speed up test collection when a project has well specified directories for tests, being usually more practical than configuring norecursedirs for all directories that do not contain tests. Thanks to Adrian for idea (#694) and Bruno Oliveira for the PR.
fix issue713: JUnit XML reports for doctest failures. Thanks Punyashloka Biswal.
fix issue970: internal pytest warnings now appear as "pytest-warnings" in the terminal instead of "warnings", so it is clear for users that those warnings are from pytest and not from the builtin "warnings" module. Thanks Bruno Oliveira.
Include setup and teardown in junitxml test durations. Thanks Janne Vanhala.
fix issue735: assertion failures on debug versions of Python 3.4+
new option --import-mode to allow to change test module importing behaviour to append to sys.path instead of prepending. This better allows to run test modules against installed versions of a package even if the package under test has the same import root. In this example:
testing/__init__.py testing/test_pkg_under_test.py pkg_under_test/
the tests will run against the installed version of pkg_under_test when --import-mode=append is used whereas by default they would always pick up the local version. Thanks Holger Krekel.
pytester: add method TmpTestdir.delete_loaded_modules(), and call it from inline_run() to allow temporary modules to be reloaded. Thanks Eduardo Schettino.
internally refactor pluginmanager API and code so that there is a clear distinction between a pytest-agnostic rather simple pluginmanager and the PytestPluginManager which adds a lot of behaviour, among it handling of the local conftest files. In terms of documented methods this is a backward compatible change but it might still break 3rd party plugins which relied on details like especially the pluginmanager.add_shutdown() API. Thanks Holger Krekel.
pluginmanagement: introduce pytest.hookimpl and pytest.hookspec decorators for setting impl/spec specific parameters. This substitutes the previous now deprecated use of pytest.mark which is meant to contain markers for test functions only.
write/refine docs for "writing plugins" which now have their own page and are separate from the "using/installing plugins`` page.
fix issue732: properly unregister plugins from any hook calling sites allowing to have temporary plugins during test execution.
deprecate and warn about __multicall__ argument in hook implementations. Use the hookwrapper mechanism instead already introduced with pytest-2.7.
speed up pytest's own test suite considerably by using inprocess tests by default (testrun can be modified with --runpytest=subprocess to create subprocesses in many places instead). The main APIs to run pytest in a test is "runpytest()" or "runpytest_subprocess" and "runpytest_inprocess" if you need a particular way of running the test. In all cases you get back a RunResult but the inprocess one will also have a "reprec" attribute with the recorded events/reports.
fix monkeypatch.setattr("x.y", raising=False) to actually not raise if "y" is not a pre-existing attribute. Thanks Florian Bruhin.
fix issue741: make running output from testdir.run copy/pasteable Thanks Bruno Oliveira.
add a new --noconftest argument which ignores all conftest.py files.
add file and line attributes to JUnit-XML output.
fix issue890: changed extension of all documentation files from txt to rst. Thanks to Abhijeet for the PR.
fix issue714: add ability to apply indirect=True parameter on particular argnames. Thanks Elizaveta239.
fix issue890: changed extension of all documentation files from txt to rst. Thanks to Abhijeet for the PR.
fix issue957: "# doctest: SKIP" option will now register doctests as SKIPPED rather than PASSED. Thanks Thomas Grainger for the report and Bruno Oliveira for the PR.
issue951: add new record_xml_property fixture, that supports logging additional information on xml output. Thanks David Diaz for the PR.
issue949: paths after normal options (for example -s, -v, etc) are now properly used to discover rootdir and ini files. Thanks Peter Lauri for the report and Bruno Oliveira for the PR.
dropped python2.5 from automated release testing of pytest itself which means it's probably going to break soon (but still works with this release we believe).
simplified and fixed implementation for calling finalizers when parametrized fixtures or function arguments are involved. finalization is now performed lazily at setup time instead of in the "teardown phase". While this might sound odd at first, it helps to ensure that we are correctly handling setup/teardown even in complex code. User-level code should not be affected unless it's implementing the pytest_runtest_teardown hook and expecting certain fixture instances are torn down within (very unlikely and would have been unreliable anyway).
PR90: add --color=yes|no|auto option to force terminal coloring mode ("auto" is default). Thanks Marc Abramowitz.
fix issue319 - correctly show unicode in assertion errors. Many thanks to Floris Bruynooghe for the complete PR. Also means we depend on py>=1.4.19 now.
fix issue396 - correctly sort and finalize class-scoped parametrized tests independently from number of methods on the class.
refix issue323 in a better way -- parametrization should now never cause Runtime Recursion errors because the underlying algorithm for re-ordering tests per-scope/per-fixture is not recursive anymore (it was tail-call recursive before which could lead to problems for more than >966 non-function scoped parameters).
fix issue290 - there is preliminary support now for parametrizing with repeated same values (sometimes useful to test if calling a second time works as with the first time).
close issue240 - document precisely how pytest module importing works, discuss the two common test directory layouts, and how it interacts with PEP420-namespace packages.
fix issue246 fix finalizer order to be LIFO on independent fixtures depending on a parametrized higher-than-function scoped fixture. (was quite some effort so please bear with the complexity of this sentence :) Thanks Ralph Schmitt for the precise failure example.
fix issue244 by implementing special index for parameters to only use indices for paramentrized test ids
fix issue287 by running all finalizers but saving the exception from the first failing finalizer and re-raising it so teardown will still have failed. We reraise the first failing exception because it might be the cause for other finalizers to fail.
fix ordering when mock.patch or other standard decorator-wrappings are used with test methods. This fixues issue346 and should help with random "xdist" collection failures. Thanks to Ronny Pfannschmidt and Donald Stufft for helping to isolate it.
fix issue357 - special case "-k" expressions to allow for filtering with simple strings that are not valid python expressions. Examples: "-k 1.3" matches all tests parametrized with 1.3. "-k None" filters all tests that have "None" in their name and conversely "-k 'not None'". Previously these examples would raise syntax errors.
fix issue384 by removing the trial support code since the unittest compat enhancements allow trial to handle it on its own
don't hide an ImportError when importing a plugin produces one. fixes issue375.
fix issue275 - allow usefixtures and autouse fixtures for running doctest text files.
fix issue380 by making --resultlog only rely on longrepr instead of the "reprcrash" attribute which only exists sometimes.
address issue122: allow @pytest.fixture(params=iterator) by exploding into a list early on.
fix pexpect-3.0 compatibility for pytest's own tests. (fixes issue386)
allow nested parametrize-value markers, thanks James Lan for the PR.
fix unicode handling with new monkeypatch.setattr(import_path, value) API. Thanks Rob Dennis. Fixes issue371.
fix unicode handling with junitxml, fixes issue368.
In assertion rewriting mode on Python 2, fix the detection of coding cookies. See issue #330.
make "--runxfail" turn imperative pytest.xfail calls into no ops (it already did neutralize pytest.mark.xfail markers)
refine pytest / pkg_resources interactions: The AssertionRewritingHook PEP302 compliant loader now registers itself with setuptools/pkg_resources properly so that the pkg_resources.resource_stream method works properly. Fixes issue366. Thanks for the investigations and full PR to Jason R. Coombs.
pytestconfig fixture is now session-scoped as it is the same object during the whole test run. Fixes issue370.
avoid one surprising case of marker malfunction/confusion:
@pytest.mark.some(lambda arg: ...) def test_function():
would not work correctly because pytest assumes @pytest.mark.some gets a function to be decorated already. We now at least detect if this arg is a lambda and thus the example will work. Thanks Alex Gaynor for bringing it up.
xfail a test on pypy that checks wrong encoding/ascii (pypy does not error out). fixes issue385.
internally make varnames() deal with classes's __init__, although it's not needed by pytest itself atm. Also fix caching. Fixes issue376.
fix issue221 - handle importing of namespace-package with no __init__.py properly.
refactor internal FixtureRequest handling to avoid monkeypatching. One of the positive user-facing effects is that the "request" object can now be used in closures.
fixed version comparison in pytest.importskip(modname, minverstring)
fix issue377 by clarifying in the nose-compat docs that pytest does not duplicate the unittest-API into the "plain" namespace.
fix verbose reporting for @mock'd test functions
known incompatibilities:
new features:
experimentally introduce a new pytest.yield_fixture decorator which accepts exactly the same parameters as pytest.fixture but mandates a yield statement instead of a return statement from fixture functions. This allows direct integration with "with-style" context managers in fixture functions and generally avoids registering of finalization callbacks in favour of treating the "after-yield" as teardown code. Thanks Andreas Pelme, Vladimir Keleshev, Floris Bruynooghe, Ronny Pfannschmidt and many others for discussions.
allow boolean expression directly with skipif/xfail if a "reason" is also specified. Rework skipping documentation to recommend "condition as booleans" because it prevents surprises when importing markers between modules. Specifying conditions as strings will remain fully supported.
reporting: color the last line red or green depending if failures/errors occurred or everything passed. thanks Christian Theunert.
make "import pdb ; pdb.set_trace()" work natively wrt capturing (no "-s" needed anymore), making pytest.set_trace() a mere shortcut.
fix issue181: --pdb now also works on collect errors (and on internal errors) . This was implemented by a slight internal refactoring and the introduction of a new hook pytest_exception_interact hook (see next item).
fix issue341: introduce new experimental hook for IDEs/terminals to intercept debugging: pytest_exception_interact(node, call, report).
new monkeypatch.setattr() variant to provide a shorter invocation for patching out classes/functions from modules:
monkeypatch.setattr("requests.get", myfunc)
will replace the "get" function of the "requests" module with myfunc.
fix issue322: tearDownClass is not run if setUpClass failed. Thanks Mathieu Agopian for the initial fix. Also make all of pytest/nose finalizer mimic the same generic behaviour: if a setupX exists and fails, don't run teardownX. This internally introduces a new method "node.addfinalizer()" helper which can only be called during the setup phase of a node.
simplify pytest.mark.parametrize() signature: allow to pass a CSV-separated string to specify argnames. For example: pytest.mark.parametrize("input,expected", [(1,2), (2,3)]) works as well as the previous: pytest.mark.parametrize(("input", "expected"), ...).
add support for setUpModule/tearDownModule detection, thanks Brian Okken.
integrate tab-completion on options through use of "argcomplete". Thanks Anthon van der Neut for the PR.
change option names to be hyphen-separated long options but keep the old spelling backward compatible. py.test -h will only show the hyphenated version, for example "--collect-only" but "--collectonly" will remain valid as well (for backward-compat reasons). Many thanks to Anthon van der Neut for the implementation and to Hynek Schlawack for pushing us.
fix issue 308 - allow to mark/xfail/skip individual parameter sets when parametrizing. Thanks Brianna Laugher.
call new experimental pytest_load_initial_conftests hook to allow 3rd party plugins to do something before a conftest is loaded.
Bug fixes:
tackle issue32 - speed up test runs of very quick test functions by reducing the relative overhead
fix issue30 - extended xfail/skipif handling and improved reporting. If you have a syntax error in your skip/xfail expressions you now get nice error reports.
Also you can now access module globals from xfail/skipif expressions so that this for example works now:
import pytest import mymodule @pytest.mark.skipif("mymodule.__version__[0] == "1") def test_function(): pass
This will not run the test function if the module's version string does not start with a "1". Note that specifying a string instead of a boolean expressions allows py.test to report meaningful information when summarizing a test run as to what conditions lead to skipping (or xfail-ing) tests.
fix issue28 - setup_method and pytest_generate_tests work together The setup_method fixture method now gets called also for test function invocations generated from the pytest_generate_tests hook.
fix issue27 - collectonly and keyword-selection (-k) now work together Also, if you do "py.test --collectonly -q" you now get a flat list of test ids that you can use to paste to the py.test commandline in order to execute a particular test.
fix issue25 avoid reported problems with --pdb and python3.2/encodings output
fix issue23 - tmpdir argument now works on Python3.2 and WindowsXP Starting with Python3.2 os.symlink may be supported. By requiring a newer py lib version the py.path.local() implementation acknowledges this.
fixed typos in the docs (thanks Victor Garcia, Brianna Laugher) and particular thanks to Laura Creighton who also reviewed parts of the documentation.
fix slightly wrong output of verbose progress reporting for classes (thanks Amaury)
more precise (avoiding of) deprecation warnings for node.Class|Function accesses
avoid std unittest assertion helper code in tracebacks (thanks Ronny)
New features
fix issue103: introduce py.test.raises as context manager, examples:
with py.test.raises(ZeroDivisionError): x = 0 1 / x with py.test.raises(RuntimeError) as excinfo: call_something() # you may do extra checks on excinfo.value|type|traceback here
(thanks Ronny Pfannschmidt)
Funcarg factories can now dynamically apply a marker to a test invocation. This is for example useful if a factory provides parameters to a test which are expected-to-fail:
def pytest_funcarg__arg(request): request.applymarker(py.test.mark.xfail(reason="flaky config")) ... def test_function(arg): ...
improved error reporting on collection and import errors. This makes use of a more general mechanism, namely that for custom test item/collect nodes node.repr_failure(excinfo) is now uniformly called so that you can override it to return a string error representation of your choice which is going to be reported as a (red) string.
introduce '--junitprefix=STR' option to prepend a prefix to all reports in the junitxml file.
Bug fixes
New features
issue91: introduce new py.test.xfail(reason) helper to imperatively mark a test as expected to fail. Can be used from within setup and test functions. This is useful especially for parametrized tests when certain configurations are expected-to-fail. In this case the declarative approach with the @py.test.mark.xfail cannot be used as it would mark all configurations as xfail.
issue102: introduce new --maxfail=NUM option to stop test runs after NUM failures. This is a generalization of the '-x' or '--exitfirst' option which is now equivalent to '--maxfail=1'. Both '-x' and '--maxfail' will now also print a line near the end indicating the Interruption.
issue89: allow py.test.mark decorators to be used on classes (class decorators were introduced with python2.6) and also allow to have multiple markers applied at class/module level by specifying a list.
improve and refine letter reporting in the progress bar: . pass f failed test s skipped tests (reminder: use for dependency/platform mismatch only) x xfailed test (test that was expected to fail) X xpassed test (test that was expected to fail but passed)
You can use any combination of 'fsxX' with the '-r' extended reporting option. The xfail/xpass results will show up as skipped tests in the junitxml output - which also fixes issue99.
make py.test.cmdline.main() return the exitstatus instead of raising SystemExit and also allow it to be called multiple times. This of course requires that your application and tests are properly teared down and don't have global state.
Bug Fixes
deprecate --report option in favour of a new shorter and easier to remember -r option: it takes a string argument consisting of any combination of 'xfsX' characters. They relate to the single chars you see during the dotted progress printing and will print an extra line per test at the end of the test run. This extra line indicates the exact position or test ID that you directly paste to the py.test cmdline in order to re-run a particular test.
allow external plugins to register new hooks via the new pytest_addhooks(pluginmanager) hook. The new release of the pytest-xdist plugin for distributed and looponfailing testing requires this feature.
add a new pytest_ignore_collect(path, config) hook to allow projects and plugins to define exclusion behaviour for their directory structure - for example you may define in a conftest.py this method:
def pytest_ignore_collect(path): return path.check(link=1)
to prevent even a collection try of any tests in symlinked dirs.
new pytest_pycollect_makemodule(path, parent) hook for allowing customization of the Module collection object for a matching test module.
extend and refine xfail mechanism: @py.test.mark.xfail(run=False) do not run the decorated test @py.test.mark.xfail(reason="...") prints the reason string in xfail summaries specifying --runxfail on command line virtually ignores xfail markers
expose (previously internal) commonly useful methods: py.io.get_terminal_with() -> return terminal width py.io.ansi_print(...) -> print colored/bold text on linux/win32 py.io.saferepr(obj) -> return limited representation string
expose test outcome related exceptions as py.test.skip.Exception, py.test.raises.Exception etc., useful mostly for plugins doing special outcome interpretation/tweaking
(issue85) fix junitxml plugin to handle tests with non-ascii output
fix/refine python3 compatibility (thanks Benjamin Peterson)
fixes for making the jython/win32 combination work, note however: jython2.5.1/win32 does not provide a command line launcher, see http://bugs.jython.org/issue1491 . See pylib install documentation for how to work around.
fixes for handling of unicode exception values and unprintable objects
(issue87) fix unboundlocal error in assertionold code
(issue86) improve documentation for looponfailing
refine IO capturing: stdin-redirect pseudo-file now has a NOP close() method
ship distribute_setup.py version 0.6.10
added links to the new capturelog and coverage plugins
refined usage and options for "py.cleanup":
py.cleanup # remove "*.pyc" and "*$py.class" (jython) files py.cleanup -e .swp -e .cache # also remove files with these extensions py.cleanup -s # remove "build" and "dist" directory next to setup.py files py.cleanup -d # also remove empty directories py.cleanup -a # synonym for "-s -d -e 'pip-log.txt'" py.cleanup -n # dry run, only show what would be removed
add a new option "py.test --funcargs" which shows available funcargs and their help strings (docstrings on their respective factory function) for a given test path
display a short and concise traceback if a funcarg lookup fails
early-load "conftest.py" files in non-dot first-level sub directories. allows to conveniently keep and access test-related options in a test subdir and still add command line options.
fix issue67: new super-short traceback-printing option: "--tb=line" will print a single line for each failing (python) test indicating its filename, lineno and the failure value
fix issue78: always call python-level teardown functions even if the according setup failed. This includes refinements for calling setup_module/class functions which will now only be called once instead of the previous behaviour where they'd be called multiple times if they raise an exception (including a Skipped exception). Any exception will be re-corded and associated with all tests in the according module/class scope.
fix issue63: assume <40 columns to be a bogus terminal width, default to 80
fix pdb debugging to be in the correct frame on raises-related errors
update apipkg.py to fix an issue where recursive imports might unnecessarily break importing
fix plugin links
XXX lots of things missing here XXX
This is a fairly complete list of v0.9.1, which can serve as a reference for developers.