Age | Commit message (Collapse) | Author |
|
permit tox config in non-tox.ini files for pytest-dev member projects
|
|
remove unused bitbucket link
|
|
|
|
|
|
Fix INTERNALERROR when accessing locals / globals with faulty `exec`
|
|
|
|
|
|
Merge pull request #7720 from pytest-dev/release-6.0.2
|
|
Prepare release 6.0.2
(cherry picked from commit fe69bd5baf6b8d1713e16caffc7a5e8dab63bc0f)
|
|
|
|
Fix #1953
|
|
doc: fix a few broken cross references
|
|
Update pytest-dev requirements
|
|
Co-authored-by: Bruno Oliveira <nicoddemus@gmail.com>
|
|
- be more vague about "packaging metadata" over explicitly mentioning `setup.py`
(such that `pyproject.toml`-based distributions are allowed)
- drop extensions on `README.txt` / `LICENSE.txt` (it's more common to have `.md`
/ `.rst` / no extension)
- remove duplicate mention of license packaging metadata
|
|
|
|
doc: Remove Workshoptage training
|
|
The sign-up is closed.
|
|
Co-authored-by: Bruno Oliveira <nicoddemus@gmail.com>
|
|
doc: prefer to reference by public name when possible
|
|
doc/reference: include PluginManager in PytestPluginManager and remove it
|
|
Use tox to execute release script
|
|
The release-on-comment script is always executed on *master*, so we should
execute the `release.py` script using tox to ensure we create the
right environment.
Also fixed errors in the error handling code.
|
|
When a name is exported from `pytest`, prefer to refer to it by that
rather than its `_pytest` import path. It is shorter and more
appropriate in user-facing documentation (although that's not really
visible).
Our plan is to expose more names for typing purposes, in which can this
could be more comprehensive.
|
|
Before, `PluginManager` was a copy of the pluggy doc, and
`PytestPluginManager` was documented separately.
pytest users only really need to know about `PytestPluginManager`, so
instead of splitting have the `PytestPluginManager` documentation
include all of `PluginManager` members and remove `PluginManager` from
the reference (it is still shown as the base class).
|
|
config: start migrating Config.{rootdir,inifile} from py.path.local to pathlib
|
|
Fix handle of exceptions in ReprEntry with tb=line
|
|
|
|
properties
|
|
|
|
Warnings are a central part of Python, so much that Python itself has
command-line and environtment variables to handle warnings.
By moving the concept of warning handling into Config, it becomes natural to
filter warnings issued as early as possible, even before the "_pytest.warnings"
plugin is given a chance to spring into action. This also avoids the weird
coupling between config and the warnings plugin that was required before.
Fix #6681
Fix #2891
Fix #7620
Fix #7626
Close #7649
Co-authored-by: Ran Benita <ran@unusedvar.com>
|
|
Fix #7707
|
|
fixture: remove `@scopeproperty`
|
|
python: small optimization in PyCollector.collect()
|
|
|
|
As related in #7696
|
|
I think the straight code is easier to understand.
|
|
Inline `_makeitem()` so that `self.ihook` (which is moderately
expensive) can be called only once.
Note: the removed test "test_makeitem_non_underscore" comes from an old
behavior of skipping names that start with `_` which has since been
generalized, making the test no longer relevant.
|
|
RFC: python: skip work pytest_pycollect_makeitem work on certain names
|
|
When a Python object (module/class/instance) is collected, for each name
in `obj.__dict__` (and up its MRO) the pytest_pycollect_makeitem hook is
called for potentially creating a node for it.
These Python objects have a bunch of builtin attributes that are
extremely unlikely to be collected. But due to their pervasiveness,
dispatching the hook for them ends up being mildly expensive and also
pollutes PYTEST_DEBUG=1 output and such.
Let's just ignore these attributes.
On the pandas test suite commit 04e9e0afd476b1b8bed930e47bf60e,
collect only, irrelevant lines snipped, about 5% improvement:
Before:
```
51195095 function calls (48844352 primitive calls) in 39.089 seconds
ncalls tottime percall cumtime percall filename:lineno(function)
226602/54 0.145 0.000 38.940 0.721 manager.py:90(_hookexec)
72227 0.285 0.000 20.146 0.000 python.py:424(_makeitem)
72227 0.171 0.000 16.678 0.000 python.py:218(pytest_pycollect_makeitem)
```
After:
```
48410921 function calls (46240870 primitive calls) in 36.950 seconds
ncalls tottime percall cumtime percall filename:lineno(function)
181429/54 0.113 0.000 36.777 0.681 manager.py:90(_hookexec)
27054 0.130 0.000 17.755 0.001 python.py:465(_makeitem)
27054 0.121 0.000 16.219 0.001 python.py:218(pytest_pycollect_makeitem)
```
|
|
python: fix empty parametrize() leading to "NotSetType.token" id
|
|
In ff8b7884e8f1019f60f270eab2c4909ff557dd4e NOTSET was changed to a
singleton enum, which ended up unexpectedly triggering a code path in ID
generation which checks for `isinstance(Enum)`.
Add an explicit case for it, which is not too bad anyway.
|
|
* Update talks/trainings page
- Remove past webinar
- Add new open training
- Add some talks/webinars by Oliver Bestwalter and by me
- Remove some stale link targets
* Move sidebar to index
|
|
Start simplifying collection code in Session
|
|
|
|
They are only used for the duration of this function.
|
|
Now all of the logic is in one place and may be simplified and
refactored in more sensible way.
|
|
This removes an unhelpful level of indirection and enables some upcoming
upcoming simplifications.
|
|
Things are easier to understand without the weird exception.
|
|
The weird name was due to f3967333a145d8a793a0ab53ac5e0cb0b6c87cac, now
that I understand it a bit better can give it a more descriptive name.
|