summaryrefslogtreecommitdiff
path: root/testing/test_session.py
AgeCommit message (Collapse)Author
2020-11-04#7942 test_session.py migrate from testdir to pytesterduthades
- Add name to AUTHORS
2020-10-03py36+: pyupgrade: py36+Anthony Sottile
2020-02-28Simplify test_rootdir_wrong_option_arg (#6812)Daniel Hahler
2020-02-10Move ExitCode's definition from _pytest.main to _pytest.configRan Benita
ExitCode is used in several internal modules and hooks and so with type annotations added, needs to be imported a lot. _pytest.main, being the entry point, generally sits at the top of the import tree. So, it's not great to have ExitCode defined in _pytest.main, because it will cause a lot of import cycles once type annotations are added (in fact there is already one, which this change removes). Move it to _pytest.config instead. _pytest.main still imports ExitCode, so importing from there still works, although external users should really be importing from `pytest`.
2019-11-06saferepr: handle BaseExceptionsDaniel Hahler
This causes INTERNALERRORs with pytest-django, which uses `pytest.fail` (derived from `BaseException`) to prevent DB access, when pytest then tries to e.g. display the `repr()` for a Django `QuerySet` etc. Ref: https://github.com/pytest-dev/pytest-django/pull/776
2019-06-15initial conversion of exit codes to enumRonny Pfannschmidt
2019-06-03pre-commit run pyupgrade --all-filesAnthony Sottile
2019-06-03pre-commit run reorder-python-imports --all-filesAnthony Sottile
2019-06-03pre-commit run fix-encoding-pragma --all-filesAnthony Sottile
2019-05-28Merge master into featuresDaniel Hahler
2019-05-14Use fix-encoding-pragma pre-commit hookAnthony Sottile
2019-05-14minor: s/no covers/no cover/Daniel Hahler
2019-04-19Fix handle repr error with showlocals and verbose outputNikolay Kondratyev
2019-03-26Merge master into featuresDaniel Hahler
2019-03-26Merge pull request #4979 from blueyed/minorDaniel Hahler
Minor: whitespace, typo, docs
2019-03-24test_implicit_bad_repr1: harden/cleanupDaniel Hahler
2019-03-24Fix pytest's own tests with `-W error::ResourceWarning`Daniel Hahler
2019-03-22Revisit coverage in some testsDaniel Hahler
2019-03-02Do not show "inifile:" string if there's no configuration fileBruno Oliveira
2019-02-06Add ability to exclude files matching glob patterns with --ignore-globChristian Fetzer
This adds the `--ignore-glob` option to allow Unix-style wildcards so that `--ignore-glob=integration*` excludes all tests that reside in files starting with `integration`. Fixes: #3711
2019-01-13Remove some dead codeAnthony Sottile
- I wrote a thing: https://github.com/asottile/dead - wanted to try it out, there's lots of false positives and I didn't look through all the things it pointed out but here's some
2018-11-30remove yield tests and compat propertiesRonny Pfannschmidt
2018-11-29Deprecate `raises(..., 'code(as_a_string)')` / `warns(..., 'code(as_a_string)')Anthony Sottile
2018-11-16fix #4400 - rearrange the handling of yield test warnings/errorsRonny Pfannschmidt
2018-11-13Merge remote-tracking branch 'upstream/master' into merge-master-into-featuresBruno Oliveira
2018-11-10Add test for --deselect without "::()"Daniel Hahler
Closes: https://github.com/pytest-dev/pytest/issues/4127.
2018-11-09Fix nodes._check_initialpaths_for_relpath for dirsDaniel Hahler
Ref: https://github.com/pytest-dev/pytest/issues/4321#issuecomment-436951894 Hardens some of the not many tests affected by this: 1. `testing/test_session.py::test_rootdir_option_arg` displayed: > root/test_rootdir_option_arg2/test_rootdir_option_arg.py 2. `test_cmdline_python_namespace_package` displayed "hello/" prefix for: > hello/test_hello.py::test_hello > hello/test_hello.py::test_other
2018-11-01Move handling of duplicate filesDaniel Hahler
This removes the hack added in https://github.com/pytest-dev/pytest/pull/3802. Adjusts test: - it appears to not have been changed to 7 intentionally. - removes XXX comment, likely not relevant anymore since 6dac7743.
2018-10-26Merge pull request #4241 from blueyed/move-duplicatesBruno Oliveira
Move handling of duplicate files
2018-10-25Move handling of duplicate filesDaniel Hahler
This removes the hack added in https://github.com/pytest-dev/pytest/pull/3802. Adjusts test: - it appears to not have been changed to 7 intentionally. - removes XXX comment, likely not relevant anymore since 6dac7743.
2018-10-25Apply reorder-python-imports to all filesAnthony Sottile
2018-06-26Upgrade pre-commit hooks except pyupgradeAnthony Sottile
2018-05-23run blackRonny Pfannschmidt
2018-02-16Add --deselect command line optionJordan Speicher
Fixes #3198
2018-02-01#1642 Fix commentsfeuillemorte
2018-02-01#1642 Fix testsfeuillemorte
2018-02-01#1642 fix tests and config.pyfeuillemorte
2018-01-25#1642 Fix testsfeuillemorte
2018-01-20#1642 Fix rootdir optionfeuillemorte
2018-01-17#1642 remove printfeuillemorte
2018-01-17#1642 Add rootdir optionfeuillemorte
2017-11-04Fix linting E741: ambiguous variable nameBruno Oliveira
2017-07-17Fixed E731 flake8 errorsAndras Tim
do not assign a lambda expression, use a def
2017-07-17Fixed E302 flake8 errorsAndras Tim
expected 2 blank lines, found 0
2017-07-17Fixed E265 flake8 errorsAndras Tim
block comment should start with ‘# ‘
2017-07-17Fixed E261 flake8 errorsAndras Tim
at least two spaces before inline comment
2017-03-16Add __future__ imports to all pytest modulesBruno Oliveira
This prevents silly errors from creeping in Python 2 when testing in Python 3
2017-03-10Merge remote-tracking branch 'upstream/master' into merge-master-into-featuresBruno Oliveira
# Conflicts: # AUTHORS # CHANGELOG.rst # _pytest/pytester.py
2017-02-16New-style classes implemented for python 2.7 - #2147Michal Wajszczuk
2017-02-15Spelling fixesVille Skyttä