11.5.2 2===== 3 4- fix #169, #170: error importing py.log on Windows: no module named ``syslog``. 5 61.5.1 7===== 8 9- fix #167 - prevent pip from installing py in unsupported Python versions. 10 111.5.0 12===== 13 14NOTE: **this release has been removed from PyPI** due to missing package 15metadata which caused a number of problems to py26 and py33 users. 16This issue was fixed in the 1.5.1 release. 17 18- python 2.6 and 3.3 are no longer supported 19- deprecate py.std and remove all internal uses 20- fix #73 turn py.error into an actual module 21- path join to / no longer produces leading double slashes 22- fix #82 - remove unsupportable aliases 23- fix python37 compatibility of path.sysfind on windows by correctly replacing vars 24- turn iniconfig and apipkg into vendored packages and ease de-vendoring for distributions 25- fix #68 remove invalid py.test.ensuretemp references 26- fix #25 - deprecate path.listdir(sort=callable) 27- add ``TerminalWriter.chars_on_current_line`` read-only property that tracks how many characters 28 have been written to the current line. 29 301.4.34 31==================================================================== 32 33- fix issue119 / pytest issue708 where tmpdir may fail to make numbered directories 34 when the filesystem is case-insensitive. 35 361.4.33 37==================================================================== 38 39- avoid imports in calls to py.path.local().fnmatch(). Thanks Andreas Pelme for 40 the PR. 41 42- fix issue106: Naive unicode encoding when calling fspath() in python2. Thanks Tiago Nobrega for the PR. 43 44- fix issue110: unittest.TestCase.assertWarns fails with py imported. 45 461.4.32 47==================================================================== 48 49- fix issue70: added ability to copy all stat info in py.path.local.copy. 50 51- make TerminalWriter.fullwidth a property. This results in the correct 52 value when the terminal gets resized. 53 54- update supported html tags to include recent additions. 55 Thanks Denis Afonso for the PR. 56 57- Remove internal code in ``Source.compile`` meant to support earlier Python 3 versions that produced the side effect 58 of leaving ``None`` in ``sys.modules`` when called (see pytest-dev/pytest#2103). 59 Thanks Bruno Oliveira for the PR. 60 611.4.31 62================================================== 63 64- fix local().copy(dest, mode=True) to also work 65 with unicode. 66 67- pass better error message with svn EEXIST paths 68 691.4.30 70================================================== 71 72- fix issue68 an assert with a multiline list comprehension 73 was not reported correctly. Thanks Henrik Heibuerger. 74 75 761.4.29 77================================================== 78 79- fix issue55: revert a change to the statement finding algorithm 80 which is used by pytest for generating tracebacks. 81 Thanks Daniel Hahler for initial analysis. 82 83- fix pytest issue254 for when traceback rendering can't 84 find valid source code. Thanks Ionel Cristian Maries. 85 86 871.4.28 88================================================== 89 90- fix issue64 -- dirpath regression when "abs=True" is passed. 91 Thanks Gilles Dartiguelongue. 92 931.4.27 94================================================== 95 96- fix issue59: point to new repo site 97 98- allow a new ensuresyspath="append" mode for py.path.local.pyimport() 99 so that a neccessary import path is appended instead of prepended to 100 sys.path 101 102- strike undocumented, untested argument to py.path.local.pypkgpath 103 104- speed up py.path.local.dirpath by a factor of 10 105 1061.4.26 107================================================== 108 109- avoid calling normpath twice in py.path.local 110 111- py.builtin._reraise properly reraises under Python3 now. 112 113- fix issue53 - remove module index, thanks jenisys. 114 115- allow posix path separators when "fnmatch" is called. 116 Thanks Christian Long for the complete PR. 117 1181.4.25 119================================================== 120 121- fix issue52: vaguely fix py25 compat of py.path.local (it's not 122 officially supported), also fix docs 123 124- fix pytest issue 589: when checking if we have a recursion error 125 check for the specific "maximum recursion depth" text of the exception. 126 1271.4.24 128================================================== 129 130- Fix retrieving source when an else: line has an other statement on 131 the same line. 132 133- add localpath read_text/write_text/read_bytes/write_bytes methods 134 as shortcuts and clearer bytes/text interfaces for read/write. 135 Adapted from a PR from Paul Moore. 136 137 1381.4.23 139================================================== 140 141- use newer apipkg version which makes attribute access on 142 alias modules resolve to None rather than an ImportError. 143 This helps with code that uses inspect.getframeinfo() 144 on py34 which causes a complete walk on sys.modules 145 thus triggering the alias module to resolve and blowing 146 up with ImportError. The negative side is that something 147 like "py.test.X" will now result in None instead of "importerror: pytest" 148 if pytest is not installed. But you shouldn't import "py.test" 149 anyway anymore. 150 151- adapt one svn test to only check for any exception instead 152 of specific ones because different svn versions cause different 153 errors and we don't care. 154 155 1561.4.22 157================================================== 158 159- refactor class-level registry on ForkedFunc child start/finish 160 event to become instance based (i.e. passed into the constructor) 161 1621.4.21 163================================================== 164 165- ForkedFunc now has class-level register_on_start/on_exit() 166 methods to allow adding information in the boxed process. 167 Thanks Marc Schlaich. 168 169- ForkedFunc in the child opens in "auto-flush" mode for 170 stdout/stderr so that when a subprocess dies you can see 171 its output even if it didn't flush itself. 172 173- refactor traceback generation in light of pytest issue 364 174 (shortening tracebacks). you can now set a new traceback style 175 on a per-entry basis such that a caller can force entries to be 176 isplayed as short or long entries. 177 178- win32: py.path.local.sysfind(name) will preferrably return files with 179 extensions so that if "X" and "X.bat" or "X.exe" is on the PATH, 180 one of the latter two will be returned. 181 1821.4.20 183================================================== 184 185- ignore unicode decode errors in xmlescape. Thanks Anatoly Bubenkoff. 186 187- on python2 modify traceback.format_exception_only to match python3 188 behaviour, namely trying to print unicode for Exception instances 189 190- use a safer way for serializing exception reports (helps to fix 191 pytest issue413) 192 193Changes between 1.4.18 and 1.4.19 194================================================== 195 196- merge in apipkg fixes 197 198- some micro-optimizations in py/_code/code.py for speeding 199 up pytest runs. Thanks Alex Gaynor for initiative. 200 201- check PY_COLORS=1 or PY_COLORS=0 to force coloring/not-coloring 202 for py.io.TerminalWriter() independently from capabilities 203 of the output file. Thanks Marc Abramowitz for the PR. 204 205- some fixes to unicode handling in assertion handling. 206 Thanks for the PR to Floris Bruynooghe. (This helps 207 to fix pytest issue 319). 208 209- depend on setuptools presence, remove distribute_setup 210 211Changes between 1.4.17 and 1.4.18 212================================================== 213 214- introduce path.ensure_dir() as a synonym for ensure(..., dir=1) 215 216- some unicode/python3 related fixes wrt to path manipulations 217 (if you start passing unicode particular in py2 you might 218 still get problems, though) 219 220Changes between 1.4.16 and 1.4.17 221================================================== 222 223- make py.io.TerminalWriter() prefer colorama if it is available 224 and avoid empty lines when separator-lines are printed by 225 being defensive and reducing the working terminalwidth by 1 226 227- introduce optional "expanduser" argument to py.path.local 228 to that local("~", expanduser=True) gives the home 229 directory of "user". 230 231Changes between 1.4.15 and 1.4.16 232================================================== 233 234- fix issue35 - define __gt__ ordering between a local path 235 and strings 236 237- fix issue36 - make chdir() work even if os.getcwd() fails. 238 239- add path.exists/isdir/isfile/islink shortcuts 240 241- introduce local path.as_cwd() context manager. 242 243- introduce p.write(ensure=1) and p.open(ensure=1) 244 where ensure triggers creation of neccessary parent 245 dirs. 246 247 248Changes between 1.4.14 and 1.4.15 249================================================== 250 251- majorly speed up some common calling patterns with 252 LocalPath.listdir()/join/check/stat functions considerably. 253 254- fix an edge case with fnmatch where a glob style pattern appeared 255 in an absolute path. 256 257Changes between 1.4.13 and 1.4.14 258================================================== 259 260- fix dupfile to work with files that don't 261 carry a mode. Thanks Jason R. Coombs. 262 263Changes between 1.4.12 and 1.4.13 264================================================== 265 266- fix getting statementrange/compiling a file ending 267 in a comment line without newline (on python2.5) 268- for local paths you can pass "mode=True" to a copy() 269 in order to copy permission bits (underlying mechanism 270 is using shutil.copymode) 271- add paths arguments to py.path.local.sysfind to restrict 272 search to the diretories in the path. 273- add isdir/isfile/islink to path.stat() objects allowing to perform 274 multiple checks without calling out multiple times 275- drop py.path.local.__new__ in favour of a simpler __init__ 276- iniconfig: allow "name:value" settings in config files, no space after 277 "name" required 278- fix issue 27 - NameError in unlikely untested case of saferepr 279 280 281Changes between 1.4.11 and 1.4.12 282================================================== 283 284- fix python2.4 support - for pre-AST interpreters re-introduce 285 old way to find statements in exceptions (closes pytest issue 209) 286- add tox.ini to distribution 287- fix issue23 - print *,** args information in tracebacks, 288 thanks Manuel Jacob 289 290 291Changes between 1.4.10 and 1.4.11 292================================================== 293 294- use _ast to determine statement ranges when printing tracebacks - 295 avoiding multi-second delays on some large test modules 296- fix an internal test to not use class-denoted pytest_funcarg__ 297- fix a doc link to bug tracker 298- try to make terminal.write() printing more robust against 299 unicodeencode/decode problems, amend according test 300- introduce py.builtin.text and py.builtin.bytes 301 to point to respective str/unicode (py2) and bytes/str (py3) types 302- fix error handling on win32/py33 for ENODIR 303 304Changes between 1.4.9 and 1.4.10 305================================================== 306 307- terminalwriter: default to encode to UTF8 if no encoding is defined 308 on the output stream 309- issue22: improve heuristic for finding the statementrange in exceptions 310 311Changes between 1.4.8 and 1.4.9 312================================================== 313 314- fix bug of path.visit() which would not recognize glob-style patterns 315 for the "rec" recursion argument 316- changed iniconfig parsing to better conform, now the chars ";" 317 and "#" only mark a comment at the stripped start of a line 318- include recent apipkg-1.2 319- change internal terminalwriter.line/reline logic to more nicely 320 support file spinners 321 322Changes between 1.4.7 and 1.4.8 323================================================== 324 325- fix issue 13 - correct handling of the tag name object in xmlgen 326- fix issue 14 - support raw attribute values in xmlgen 327- fix windows terminalwriter printing/re-line problem 328- update distribute_setup.py to 0.6.27 329 330Changes between 1.4.6 and 1.4.7 331================================================== 332 333- fix issue11 - own test failure with python3.3 / Thanks Benjamin Peterson 334- help fix pytest issue 102 335 336Changes between 1.4.5 and 1.4.6 337================================================== 338 339- help to fix pytest issue99: unify output of 340 ExceptionInfo.getrepr(style="native") with ...(style="long") 341- fix issue7: source.getstatementrange() now raises proper error 342 if no valid statement can be found 343- fix issue8: fix code and tests of svnurl/svnwc to work on subversion 1.7 - 344 note that path.status(updates=1) will not properly work svn-17's status 345 --xml output is broken. 346- make source.getstatementrange() more resilent about non-python code frames 347 (as seen from jnja2) 348- make trackeback recursion detection more resilent 349 about the eval magic of a decorator library 350- iniconfig: add support for ; as comment starter 351- properly handle lists in xmlgen on python3 352- normalize py.code.getfslineno(obj) to always return a (string, int) tuple 353 defaulting to ("", -1) respectively if no source code can be found for obj. 354 355Changes between 1.4.4 and 1.4.5 356================================================== 357 358- improve some unicode handling in terminalwriter and capturing 359 (used by pytest) 360 361Changes between 1.4.3 and 1.4.4 362================================================== 363 364- a few fixes and assertion related refinements for pytest-2.1 365- guard py.code.Code and getfslineno against bogus input 366 and make py.code.Code objects for object instance 367 by looking up their __call__ function. 368- make exception presentation robust against invalid current cwd 369 370Changes between 1.4.2 and 1.4.3 371================================================== 372 373- fix terminal coloring issue for skipped tests (thanks Amaury) 374- fix issue4 - large calls to ansi_print (thanks Amaury) 375 376Changes between 1.4.1 and 1.4.2 377================================================== 378 379- fix (pytest) issue23 - tmpdir argument now works on Python3.2 and WindowsXP 380 (which apparently starts to offer os.symlink now) 381 382- better error message for syntax errors from compiled code 383 384- small fix to better deal with (un-)colored terminal output on windows 385 386Changes between 1.4.0 and 1.4.1 387================================================== 388 389- fix issue1 - py.error.* classes to be pickleable 390 391- fix issue2 - on windows32 use PATHEXT as the list of potential 392 extensions to find find binaries with py.path.local.sysfind(commandname) 393 394- fix (pytest-) issue10 and refine assertion reinterpretation 395 to avoid breaking if the __nonzero__ of an object fails 396 397- fix (pytest-) issue17 where python3 does not like "import *" 398 leading to misrepresentation of import-errors in test modules 399 400- fix py.error.* attribute pypy access issue 401 402- allow path.samefile(arg) to succeed when arg is a relative filename 403 404- fix (pytest-) issue20 path.samefile(relpath) works as expected now 405 406- fix (pytest-) issue8 len(long_list) now shows the length of the list 407 408Changes between 1.3.4 and 1.4.0 409================================================== 410 411- py.test was moved to a separate "pytest" package. What remains is 412 a stub hook which will proxy ``import py.test`` to ``pytest``. 413- all command line tools ("py.cleanup/lookup/countloc/..." moved 414 to "pycmd" package) 415- removed the old and deprecated "py.magic" namespace 416- use apipkg-1.1 and make py.apipkg.initpkg|ApiModule available 417- add py.iniconfig module for brain-dead easy ini-config file parsing 418- introduce py.builtin.any() 419- path objects have a .dirname attribute now (equivalent to 420 os.path.dirname(path)) 421- path.visit() accepts breadthfirst (bf) and sort options 422- remove deprecated py.compat namespace 423 424Changes between 1.3.3 and 1.3.4 425================================================== 426 427- fix issue111: improve install documentation for windows 428- fix issue119: fix custom collectability of __init__.py as a module 429- fix issue116: --doctestmodules work with __init__.py files as well 430- fix issue115: unify internal exception passthrough/catching/GeneratorExit 431- fix issue118: new --tb=native for presenting cpython-standard exceptions 432 433Changes between 1.3.2 and 1.3.3 434================================================== 435 436- fix issue113: assertion representation problem with triple-quoted strings 437 (and possibly other cases) 438- make conftest loading detect that a conftest file with the same 439 content was already loaded, avoids surprises in nested directory structures 440 which can be produced e.g. by Hudson. It probably removes the need to use 441 --confcutdir in most cases. 442- fix terminal coloring for win32 443 (thanks Michael Foord for reporting) 444- fix weirdness: make terminal width detection work on stdout instead of stdin 445 (thanks Armin Ronacher for reporting) 446- remove trailing whitespace in all py/text distribution files 447 448Changes between 1.3.1 and 1.3.2 449================================================== 450 451New features 452++++++++++++++++++ 453 454- fix issue103: introduce py.test.raises as context manager, examples:: 455 456 with py.test.raises(ZeroDivisionError): 457 x = 0 458 1 / x 459 460 with py.test.raises(RuntimeError) as excinfo: 461 call_something() 462 463 # you may do extra checks on excinfo.value|type|traceback here 464 465 (thanks Ronny Pfannschmidt) 466 467- Funcarg factories can now dynamically apply a marker to a 468 test invocation. This is for example useful if a factory 469 provides parameters to a test which are expected-to-fail:: 470 471 def pytest_funcarg__arg(request): 472 request.applymarker(py.test.mark.xfail(reason="flaky config")) 473 ... 474 475 def test_function(arg): 476 ... 477 478- improved error reporting on collection and import errors. This makes 479 use of a more general mechanism, namely that for custom test item/collect 480 nodes ``node.repr_failure(excinfo)`` is now uniformly called so that you can 481 override it to return a string error representation of your choice 482 which is going to be reported as a (red) string. 483 484- introduce '--junitprefix=STR' option to prepend a prefix 485 to all reports in the junitxml file. 486 487Bug fixes / Maintenance 488++++++++++++++++++++++++++ 489 490- make tests and the ``pytest_recwarn`` plugin in particular fully compatible 491 to Python2.7 (if you use the ``recwarn`` funcarg warnings will be enabled so that 492 you can properly check for their existence in a cross-python manner). 493- refine --pdb: ignore xfailed tests, unify its TB-reporting and 494 don't display failures again at the end. 495- fix assertion interpretation with the ** operator (thanks Benjamin Peterson) 496- fix issue105 assignment on the same line as a failing assertion (thanks Benjamin Peterson) 497- fix issue104 proper escaping for test names in junitxml plugin (thanks anonymous) 498- fix issue57 -f|--looponfail to work with xpassing tests (thanks Ronny) 499- fix issue92 collectonly reporter and --pastebin (thanks Benjamin Peterson) 500- fix py.code.compile(source) to generate unique filenames 501- fix assertion re-interp problems on PyPy, by defering code 502 compilation to the (overridable) Frame.eval class. (thanks Amaury Forgeot) 503- fix py.path.local.pyimport() to work with directories 504- streamline py.path.local.mkdtemp implementation and usage 505- don't print empty lines when showing junitxml-filename 506- add optional boolean ignore_errors parameter to py.path.local.remove 507- fix terminal writing on win32/python2.4 508- py.process.cmdexec() now tries harder to return properly encoded unicode objects 509 on all python versions 510- install plain py.test/py.which scripts also for Jython, this helps to 511 get canonical script paths in virtualenv situations 512- make path.bestrelpath(path) return ".", note that when calling 513 X.bestrelpath the assumption is that X is a directory. 514- make initial conftest discovery ignore "--" prefixed arguments 515- fix resultlog plugin when used in an multicpu/multihost xdist situation 516 (thanks Jakub Gustak) 517- perform distributed testing related reporting in the xdist-plugin 518 rather than having dist-related code in the generic py.test 519 distribution 520- fix homedir detection on Windows 521- ship distribute_setup.py version 0.6.13 522 523Changes between 1.3.0 and 1.3.1 524================================================== 525 526New features 527++++++++++++++++++ 528 529- issue91: introduce new py.test.xfail(reason) helper 530 to imperatively mark a test as expected to fail. Can 531 be used from within setup and test functions. This is 532 useful especially for parametrized tests when certain 533 configurations are expected-to-fail. In this case the 534 declarative approach with the @py.test.mark.xfail cannot 535 be used as it would mark all configurations as xfail. 536 537- issue102: introduce new --maxfail=NUM option to stop 538 test runs after NUM failures. This is a generalization 539 of the '-x' or '--exitfirst' option which is now equivalent 540 to '--maxfail=1'. Both '-x' and '--maxfail' will 541 now also print a line near the end indicating the Interruption. 542 543- issue89: allow py.test.mark decorators to be used on classes 544 (class decorators were introduced with python2.6) and 545 also allow to have multiple markers applied at class/module level 546 by specifying a list. 547 548- improve and refine letter reporting in the progress bar: 549 . pass 550 f failed test 551 s skipped tests (reminder: use for dependency/platform mismatch only) 552 x xfailed test (test that was expected to fail) 553 X xpassed test (test that was expected to fail but passed) 554 555 You can use any combination of 'fsxX' with the '-r' extended 556 reporting option. The xfail/xpass results will show up as 557 skipped tests in the junitxml output - which also fixes 558 issue99. 559 560- make py.test.cmdline.main() return the exitstatus instead of raising 561 SystemExit and also allow it to be called multiple times. This of 562 course requires that your application and tests are properly teared 563 down and don't have global state. 564 565Fixes / Maintenance 566++++++++++++++++++++++ 567 568- improved traceback presentation: 569 - improved and unified reporting for "--tb=short" option 570 - Errors during test module imports are much shorter, (using --tb=short style) 571 - raises shows shorter more relevant tracebacks 572 - --fulltrace now more systematically makes traces longer / inhibits cutting 573 574- improve support for raises and other dynamically compiled code by 575 manipulating python's linecache.cache instead of the previous 576 rather hacky way of creating custom code objects. This makes 577 it seemlessly work on Jython and PyPy where it previously didn't. 578 579- fix issue96: make capturing more resilient against Control-C 580 interruptions (involved somewhat substantial refactoring 581 to the underlying capturing functionality to avoid race 582 conditions). 583 584- fix chaining of conditional skipif/xfail decorators - so it works now 585 as expected to use multiple @py.test.mark.skipif(condition) decorators, 586 including specific reporting which of the conditions lead to skipping. 587 588- fix issue95: late-import zlib so that it's not required 589 for general py.test startup. 590 591- fix issue94: make reporting more robust against bogus source code 592 (and internally be more careful when presenting unexpected byte sequences) 593 594 595Changes between 1.2.1 and 1.3.0 596================================================== 597 598- deprecate --report option in favour of a new shorter and easier to 599 remember -r option: it takes a string argument consisting of any 600 combination of 'xfsX' characters. They relate to the single chars 601 you see during the dotted progress printing and will print an extra line 602 per test at the end of the test run. This extra line indicates the exact 603 position or test ID that you directly paste to the py.test cmdline in order 604 to re-run a particular test. 605 606- allow external plugins to register new hooks via the new 607 pytest_addhooks(pluginmanager) hook. The new release of 608 the pytest-xdist plugin for distributed and looponfailing 609 testing requires this feature. 610 611- add a new pytest_ignore_collect(path, config) hook to allow projects and 612 plugins to define exclusion behaviour for their directory structure - 613 for example you may define in a conftest.py this method:: 614 615 def pytest_ignore_collect(path): 616 return path.check(link=1) 617 618 to prevent even a collection try of any tests in symlinked dirs. 619 620- new pytest_pycollect_makemodule(path, parent) hook for 621 allowing customization of the Module collection object for a 622 matching test module. 623 624- extend and refine xfail mechanism: 625 ``@py.test.mark.xfail(run=False)`` do not run the decorated test 626 ``@py.test.mark.xfail(reason="...")`` prints the reason string in xfail summaries 627 specifiying ``--runxfail`` on command line virtually ignores xfail markers 628 629- expose (previously internal) commonly useful methods: 630 py.io.get_terminal_with() -> return terminal width 631 py.io.ansi_print(...) -> print colored/bold text on linux/win32 632 py.io.saferepr(obj) -> return limited representation string 633 634- expose test outcome related exceptions as py.test.skip.Exception, 635 py.test.raises.Exception etc., useful mostly for plugins 636 doing special outcome interpretation/tweaking 637 638- (issue85) fix junitxml plugin to handle tests with non-ascii output 639 640- fix/refine python3 compatibility (thanks Benjamin Peterson) 641 642- fixes for making the jython/win32 combination work, note however: 643 jython2.5.1/win32 does not provide a command line launcher, see 644 http://bugs.jython.org/issue1491 . See pylib install documentation 645 for how to work around. 646 647- fixes for handling of unicode exception values and unprintable objects 648 649- (issue87) fix unboundlocal error in assertionold code 650 651- (issue86) improve documentation for looponfailing 652 653- refine IO capturing: stdin-redirect pseudo-file now has a NOP close() method 654 655- ship distribute_setup.py version 0.6.10 656 657- added links to the new capturelog and coverage plugins 658 659 660Changes between 1.2.1 and 1.2.0 661===================================== 662 663- refined usage and options for "py.cleanup":: 664 665 py.cleanup # remove "*.pyc" and "*$py.class" (jython) files 666 py.cleanup -e .swp -e .cache # also remove files with these extensions 667 py.cleanup -s # remove "build" and "dist" directory next to setup.py files 668 py.cleanup -d # also remove empty directories 669 py.cleanup -a # synonym for "-s -d -e 'pip-log.txt'" 670 py.cleanup -n # dry run, only show what would be removed 671 672- add a new option "py.test --funcargs" which shows available funcargs 673 and their help strings (docstrings on their respective factory function) 674 for a given test path 675 676- display a short and concise traceback if a funcarg lookup fails 677 678- early-load "conftest.py" files in non-dot first-level sub directories. 679 allows to conveniently keep and access test-related options in a ``test`` 680 subdir and still add command line options. 681 682- 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 683 684- fix issue78: always call python-level teardown functions even if the 685 according setup failed. This includes refinements for calling setup_module/class functions 686 which will now only be called once instead of the previous behaviour where they'd be called 687 multiple times if they raise an exception (including a Skipped exception). Any exception 688 will be re-corded and associated with all tests in the according module/class scope. 689 690- fix issue63: assume <40 columns to be a bogus terminal width, default to 80 691 692- fix pdb debugging to be in the correct frame on raises-related errors 693 694- update apipkg.py to fix an issue where recursive imports might 695 unnecessarily break importing 696 697- fix plugin links 698 699Changes between 1.2 and 1.1.1 700===================================== 701 702- moved dist/looponfailing from py.test core into a new 703 separately released pytest-xdist plugin. 704 705- new junitxml plugin: --junitxml=path will generate a junit style xml file 706 which is processable e.g. by the Hudson CI system. 707 708- new option: --genscript=path will generate a standalone py.test script 709 which will not need any libraries installed. thanks to Ralf Schmitt. 710 711- new option: --ignore will prevent specified path from collection. 712 Can be specified multiple times. 713 714- new option: --confcutdir=dir will make py.test only consider conftest 715 files that are relative to the specified dir. 716 717- new funcarg: "pytestconfig" is the pytest config object for access 718 to command line args and can now be easily used in a test. 719 720- install 'py.test' and `py.which` with a ``-$VERSION`` suffix to 721 disambiguate between Python3, python2.X, Jython and PyPy installed versions. 722 723- new "pytestconfig" funcarg allows access to test config object 724 725- new "pytest_report_header" hook can return additional lines 726 to be displayed at the header of a test run. 727 728- (experimental) allow "py.test path::name1::name2::..." for pointing 729 to a test within a test collection directly. This might eventually 730 evolve as a full substitute to "-k" specifications. 731 732- streamlined plugin loading: order is now as documented in 733 customize.html: setuptools, ENV, commandline, conftest. 734 also setuptools entry point names are turned to canonical namees ("pytest_*") 735 736- automatically skip tests that need 'capfd' but have no os.dup 737 738- allow pytest_generate_tests to be defined in classes as well 739 740- deprecate usage of 'disabled' attribute in favour of pytestmark 741- deprecate definition of Directory, Module, Class and Function nodes 742 in conftest.py files. Use pytest collect hooks instead. 743 744- collection/item node specific runtest/collect hooks are only called exactly 745 on matching conftest.py files, i.e. ones which are exactly below 746 the filesystem path of an item 747 748- change: the first pytest_collect_directory hook to return something 749 will now prevent further hooks to be called. 750 751- change: figleaf plugin now requires --figleaf to run. Also 752 change its long command line options to be a bit shorter (see py.test -h). 753 754- change: pytest doctest plugin is now enabled by default and has a 755 new option --doctest-glob to set a pattern for file matches. 756 757- change: remove internal py._* helper vars, only keep py._pydir 758 759- robustify capturing to survive if custom pytest_runtest_setup 760 code failed and prevented the capturing setup code from running. 761 762- make py.test.* helpers provided by default plugins visible early - 763 works transparently both for pydoc and for interactive sessions 764 which will regularly see e.g. py.test.mark and py.test.importorskip. 765 766- simplify internal plugin manager machinery 767- simplify internal collection tree by introducing a RootCollector node 768 769- fix assert reinterpreation that sees a call containing "keyword=..." 770 771- fix issue66: invoke pytest_sessionstart and pytest_sessionfinish 772 hooks on slaves during dist-testing, report module/session teardown 773 hooks correctly. 774 775- fix issue65: properly handle dist-testing if no 776 execnet/py lib installed remotely. 777 778- skip some install-tests if no execnet is available 779 780- fix docs, fix internal bin/ script generation 781 782 783Changes between 1.1.1 and 1.1.0 784===================================== 785 786- introduce automatic plugin registration via 'pytest11' 787 entrypoints via setuptools' pkg_resources.iter_entry_points 788 789- fix py.test dist-testing to work with execnet >= 1.0.0b4 790 791- re-introduce py.test.cmdline.main() for better backward compatibility 792 793- svn paths: fix a bug with path.check(versioned=True) for svn paths, 794 allow '%' in svn paths, make svnwc.update() default to interactive mode 795 like in 1.0.x and add svnwc.update(interactive=False) to inhibit interaction. 796 797- refine distributed tarball to contain test and no pyc files 798 799- try harder to have deprecation warnings for py.compat.* accesses 800 report a correct location 801 802Changes between 1.1.0 and 1.0.2 803===================================== 804 805* adjust and improve docs 806 807* remove py.rest tool and internal namespace - it was 808 never really advertised and can still be used with 809 the old release if needed. If there is interest 810 it could be revived into its own tool i guess. 811 812* fix issue48 and issue59: raise an Error if the module 813 from an imported test file does not seem to come from 814 the filepath - avoids "same-name" confusion that has 815 been reported repeatedly 816 817* merged Ronny's nose-compatibility hacks: now 818 nose-style setup_module() and setup() functions are 819 supported 820 821* introduce generalized py.test.mark function marking 822 823* reshuffle / refine command line grouping 824 825* deprecate parser.addgroup in favour of getgroup which creates option group 826 827* add --report command line option that allows to control showing of skipped/xfailed sections 828 829* generalized skipping: a new way to mark python functions with skipif or xfail 830 at function, class and modules level based on platform or sys-module attributes. 831 832* extend py.test.mark decorator to allow for positional args 833 834* introduce and test "py.cleanup -d" to remove empty directories 835 836* fix issue #59 - robustify unittest test collection 837 838* make bpython/help interaction work by adding an __all__ attribute 839 to ApiModule, cleanup initpkg 840 841* use MIT license for pylib, add some contributors 842 843* remove py.execnet code and substitute all usages with 'execnet' proper 844 845* fix issue50 - cached_setup now caches more to expectations 846 for test functions with multiple arguments. 847 848* merge Jarko's fixes, issue #45 and #46 849 850* add the ability to specify a path for py.lookup to search in 851 852* fix a funcarg cached_setup bug probably only occuring 853 in distributed testing and "module" scope with teardown. 854 855* many fixes and changes for making the code base python3 compatible, 856 many thanks to Benjamin Peterson for helping with this. 857 858* consolidate builtins implementation to be compatible with >=2.3, 859 add helpers to ease keeping 2 and 3k compatible code 860 861* deprecate py.compat.doctest|subprocess|textwrap|optparse 862 863* deprecate py.magic.autopath, remove py/magic directory 864 865* move pytest assertion handling to py/code and a pytest_assertion 866 plugin, add "--no-assert" option, deprecate py.magic namespaces 867 in favour of (less) py.code ones. 868 869* consolidate and cleanup py/code classes and files 870 871* cleanup py/misc, move tests to bin-for-dist 872 873* introduce delattr/delitem/delenv methods to py.test's monkeypatch funcarg 874 875* consolidate py.log implementation, remove old approach. 876 877* introduce py.io.TextIO and py.io.BytesIO for distinguishing between 878 text/unicode and byte-streams (uses underlying standard lib io.* 879 if available) 880 881* make py.unittest_convert helper script available which converts "unittest.py" 882 style files into the simpler assert/direct-test-classes py.test/nosetests 883 style. The script was written by Laura Creighton. 884 885* simplified internal localpath implementation 886 887Changes between 1.0.1 and 1.0.2 888===================================== 889 890* fixing packaging issues, triggered by fedora redhat packaging, 891 also added doc, examples and contrib dirs to the tarball. 892 893* added a documentation link to the new django plugin. 894 895Changes between 1.0.0 and 1.0.1 896===================================== 897 898* added a 'pytest_nose' plugin which handles nose.SkipTest, 899 nose-style function/method/generator setup/teardown and 900 tries to report functions correctly. 901 902* capturing of unicode writes or encoded strings to sys.stdout/err 903 work better, also terminalwriting was adapted and somewhat 904 unified between windows and linux. 905 906* improved documentation layout and content a lot 907 908* added a "--help-config" option to show conftest.py / ENV-var names for 909 all longopt cmdline options, and some special conftest.py variables. 910 renamed 'conf_capture' conftest setting to 'option_capture' accordingly. 911 912* fix issue #27: better reporting on non-collectable items given on commandline 913 (e.g. pyc files) 914 915* fix issue #33: added --version flag (thanks Benjamin Peterson) 916 917* fix issue #32: adding support for "incomplete" paths to wcpath.status() 918 919* "Test" prefixed classes are *not* collected by default anymore if they 920 have an __init__ method 921 922* monkeypatch setenv() now accepts a "prepend" parameter 923 924* improved reporting of collection error tracebacks 925 926* simplified multicall mechanism and plugin architecture, 927 renamed some internal methods and argnames 928 929Changes between 1.0.0b9 and 1.0.0 930===================================== 931 932* more terse reporting try to show filesystem path relatively to current dir 933* improve xfail output a bit 934 935Changes between 1.0.0b8 and 1.0.0b9 936===================================== 937 938* cleanly handle and report final teardown of test setup 939 940* fix svn-1.6 compat issue with py.path.svnwc().versioned() 941 (thanks Wouter Vanden Hove) 942 943* setup/teardown or collection problems now show as ERRORs 944 or with big "E"'s in the progress lines. they are reported 945 and counted separately. 946 947* dist-testing: properly handle test items that get locally 948 collected but cannot be collected on the remote side - often 949 due to platform/dependency reasons 950 951* simplified py.test.mark API - see keyword plugin documentation 952 953* integrate better with logging: capturing now by default captures 954 test functions and their immediate setup/teardown in a single stream 955 956* capsys and capfd funcargs now have a readouterr() and a close() method 957 (underlyingly py.io.StdCapture/FD objects are used which grew a 958 readouterr() method as well to return snapshots of captured out/err) 959 960* make assert-reinterpretation work better with comparisons not 961 returning bools (reported with numpy from thanks maciej fijalkowski) 962 963* reworked per-test output capturing into the pytest_iocapture.py plugin 964 and thus removed capturing code from config object 965 966* item.repr_failure(excinfo) instead of item.repr_failure(excinfo, outerr) 967 968 969Changes between 1.0.0b7 and 1.0.0b8 970===================================== 971 972* pytest_unittest-plugin is now enabled by default 973 974* introduced pytest_keyboardinterrupt hook and 975 refined pytest_sessionfinish hooked, added tests. 976 977* workaround a buggy logging module interaction ("closing already closed 978 files"). Thanks to Sridhar Ratnakumar for triggering. 979 980* if plugins use "py.test.importorskip" for importing 981 a dependency only a warning will be issued instead 982 of exiting the testing process. 983 984* many improvements to docs: 985 - refined funcargs doc , use the term "factory" instead of "provider" 986 - added a new talk/tutorial doc page 987 - better download page 988 - better plugin docstrings 989 - added new plugins page and automatic doc generation script 990 991* fixed teardown problem related to partially failing funcarg setups 992 (thanks MrTopf for reporting), "pytest_runtest_teardown" is now 993 always invoked even if the "pytest_runtest_setup" failed. 994 995* tweaked doctest output for docstrings in py modules, 996 thanks Radomir. 997 998Changes between 1.0.0b3 and 1.0.0b7 999============================================= 1000 1001* renamed py.test.xfail back to py.test.mark.xfail to avoid 1002 two ways to decorate for xfail 1003 1004* re-added py.test.mark decorator for setting keywords on functions 1005 (it was actually documented so removing it was not nice) 1006 1007* remove scope-argument from request.addfinalizer() because 1008 request.cached_setup has the scope arg. TOOWTDI. 1009 1010* perform setup finalization before reporting failures 1011 1012* apply modified patches from Andreas Kloeckner to allow 1013 test functions to have no func_code (#22) and to make 1014 "-k" and function keywords work (#20) 1015 1016* apply patch from Daniel Peolzleithner (issue #23) 1017 1018* resolve issue #18, multiprocessing.Manager() and 1019 redirection clash 1020 1021* make __name__ == "__channelexec__" for remote_exec code 1022 1023Changes between 1.0.0b1 and 1.0.0b3 1024============================================= 1025 1026* plugin classes are removed: one now defines 1027 hooks directly in conftest.py or global pytest_*.py 1028 files. 1029 1030* added new pytest_namespace(config) hook that allows 1031 to inject helpers directly to the py.test.* namespace. 1032 1033* documented and refined many hooks 1034 1035* added new style of generative tests via 1036 pytest_generate_tests hook that integrates 1037 well with function arguments. 1038 1039 1040Changes between 0.9.2 and 1.0.0b1 1041============================================= 1042 1043* introduced new "funcarg" setup method, 1044 see doc/test/funcarg.txt 1045 1046* introduced plugin architecuture and many 1047 new py.test plugins, see 1048 doc/test/plugins.txt 1049 1050* teardown_method is now guaranteed to get 1051 called after a test method has run. 1052 1053* new method: py.test.importorskip(mod,minversion) 1054 will either import or call py.test.skip() 1055 1056* completely revised internal py.test architecture 1057 1058* new py.process.ForkedFunc object allowing to 1059 fork execution of a function to a sub process 1060 and getting a result back. 1061 1062XXX lots of things missing here XXX 1063 1064Changes between 0.9.1 and 0.9.2 1065=============================== 1066 1067* refined installation and metadata, created new setup.py, 1068 now based on setuptools/ez_setup (thanks to Ralf Schmitt 1069 for his support). 1070 1071* improved the way of making py.* scripts available in 1072 windows environments, they are now added to the 1073 Scripts directory as ".cmd" files. 1074 1075* py.path.svnwc.status() now is more complete and 1076 uses xml output from the 'svn' command if available 1077 (Guido Wesdorp) 1078 1079* fix for py.path.svn* to work with svn 1.5 1080 (Chris Lamb) 1081 1082* fix path.relto(otherpath) method on windows to 1083 use normcase for checking if a path is relative. 1084 1085* py.test's traceback is better parseable from editors 1086 (follows the filenames:LINENO: MSG convention) 1087 (thanks to Osmo Salomaa) 1088 1089* fix to javascript-generation, "py.test --runbrowser" 1090 should work more reliably now 1091 1092* removed previously accidentally added 1093 py.test.broken and py.test.notimplemented helpers. 1094 1095* there now is a py.__version__ attribute 1096 1097Changes between 0.9.0 and 0.9.1 1098=============================== 1099 1100This is a fairly complete list of changes between 0.9 and 0.9.1, which can 1101serve as a reference for developers. 1102 1103* allowing + signs in py.path.svn urls [39106] 1104* fixed support for Failed exceptions without excinfo in py.test [39340] 1105* added support for killing processes for Windows (as well as platforms that 1106 support os.kill) in py.misc.killproc [39655] 1107* added setup/teardown for generative tests to py.test [40702] 1108* added detection of FAILED TO LOAD MODULE to py.test [40703, 40738, 40739] 1109* fixed problem with calling .remove() on wcpaths of non-versioned files in 1110 py.path [44248] 1111* fixed some import and inheritance issues in py.test [41480, 44648, 44655] 1112* fail to run greenlet tests when pypy is available, but without stackless 1113 [45294] 1114* small fixes in rsession tests [45295] 1115* fixed issue with 2.5 type representations in py.test [45483, 45484] 1116* made that internal reporting issues displaying is done atomically in py.test 1117 [45518] 1118* made that non-existing files are igored by the py.lookup script [45519] 1119* improved exception name creation in py.test [45535] 1120* made that less threads are used in execnet [merge in 45539] 1121* removed lock required for atomical reporting issue displaying in py.test 1122 [45545] 1123* removed globals from execnet [45541, 45547] 1124* refactored cleanup mechanics, made that setDaemon is set to 1 to make atexit 1125 get called in 2.5 (py.execnet) [45548] 1126* fixed bug in joining threads in py.execnet's servemain [45549] 1127* refactored py.test.rsession tests to not rely on exact output format anymore 1128 [45646] 1129* using repr() on test outcome [45647] 1130* added 'Reason' classes for py.test.skip() [45648, 45649] 1131* killed some unnecessary sanity check in py.test.collect [45655] 1132* avoid using os.tmpfile() in py.io.fdcapture because on Windows it's only 1133 usable by Administrators [45901] 1134* added support for locking and non-recursive commits to py.path.svnwc [45994] 1135* locking files in py.execnet to prevent CPython from segfaulting [46010] 1136* added export() method to py.path.svnurl 1137* fixed -d -x in py.test [47277] 1138* fixed argument concatenation problem in py.path.svnwc [49423] 1139* restore py.test behaviour that it exits with code 1 when there are failures 1140 [49974] 1141* don't fail on html files that don't have an accompanying .txt file [50606] 1142* fixed 'utestconvert.py < input' [50645] 1143* small fix for code indentation in py.code.source [50755] 1144* fix _docgen.py documentation building [51285] 1145* improved checks for source representation of code blocks in py.test [51292] 1146* added support for passing authentication to py.path.svn* objects [52000, 1147 52001] 1148* removed sorted() call for py.apigen tests in favour of [].sort() to support 1149 Python 2.3 [52481] 1150