pythonPackages.pytest*: Move pytest to buildInputs to allow easy overriding pytest

This commit is contained in:
Sandro Jäckel 2021-03-12 23:20:19 +01:00 committed by Frederik Rietdijk
parent 970aea96fa
commit 60a10e0989
45 changed files with 92 additions and 46 deletions

View File

@ -9,7 +9,9 @@ buildPythonPackage rec {
sha256 = "0kx4mbs9bflycd8x9af0idcjhdgnzri3nw1qb0vpfyb3751qaaf9";
};
propagatedBuildInputs = [ pytest aiohttp ];
buildInputs = [ pytest ];
propagatedBuildInputs = [ aiohttp ];
# There are no tests
doCheck = false;

View File

@ -21,10 +21,12 @@ buildPythonPackage rec {
sed -i "s/'setuptools-markdown'//g" setup.py
'';
buildInputs = [ pytest ];
# requires pandoc < 2.0
# buildInputs = [ setuptools-markdown ];
checkInputs = [ mock ];
propagatedBuildInputs = [ ansible pytest ];
propagatedBuildInputs = [ ansible ];
# tests not included with release, even on github
doCheck = false;

View File

@ -16,10 +16,11 @@ buildPythonPackage rec {
sha256 = "de2d62f53ecc107ed754d70d562adfa7573677a263216a7f19aa332f20dc6c15";
};
buildInputs = [ pytest ];
propagatedBuildInputs = [
numpy
six
pytest
];
# The tests requires astropy, which itself requires

View File

@ -31,8 +31,7 @@ buildPythonPackage rec {
})
];
propagatedBuildInputs = [
buildInputs = [
pytest
];

View File

@ -25,9 +25,10 @@ buildPythonPackage rec {
setuptools_scm
];
buildInputs = [ pytest ];
propagatedBuildInputs = [
hypothesis
pytest
pytest-astropy-header
pytest-doctestplus
pytest-filter-subpackage

View File

@ -22,7 +22,9 @@ buildPythonPackage rec {
sha256 = "1yqzz44as4pxffmg4hk9lijvnvlc2chg1maq1fbj5i4k4jpagvjz";
};
propagatedBuildInputs = [ glob2 Mako parse parse-type py pytest six ];
buildInputs = [ pytest ];
propagatedBuildInputs = [ glob2 Mako parse parse-type py six ];
# Tests require extra dependencies
checkInputs = [ execnet mock pytest ];

View File

@ -19,7 +19,9 @@ buildPythonPackage rec {
sha256 = "1hslzzinpwc1zqhbpllqh3sllmiyk69pcycl7ahr0rz3micgwczj";
};
propagatedBuildInputs = [ pytest py-cpuinfo ] ++ lib.optionals (pythonOlder "3.4") [ pathlib statistics ];
buildInputs = [ pytest ];
propagatedBuildInputs = [ py-cpuinfo ] ++ lib.optionals (pythonOlder "3.4") [ pathlib statistics ];
meta = {
description = "Py.test fixture for benchmarking code";

View File

@ -16,7 +16,9 @@ buildPythonPackage rec {
nativeBuildInputs = [ setuptools_scm ];
propagatedBuildInputs = [ black pytest toml ];
buildInputs = [ pytest ];
propagatedBuildInputs = [ black toml ];
# does not contain tests
doCheck = false;

View File

@ -15,7 +15,7 @@ buildPythonPackage rec {
sha256 = "1i01i5ab06ic11na13gcacrlcs2ab6rmaii0yz0x06z5ynnljn6s";
};
propagatedBuildInputs = [ pytest ];
buildInputs = [ pytest ];
checkInputs = [ pytestCheckHook ];
meta = with lib; {

View File

@ -19,8 +19,9 @@ buildPythonPackage rec {
sha256 = "197nvlqlyfrqpy5lrkmfh1ywpr6j9zipxl9d7syg2a2n7jz3a8rj";
};
buildInputs = [ pytest ];
propagatedBuildInputs = [
pytest
click
];

View File

@ -9,7 +9,7 @@ buildPythonPackage rec {
sha256 = "c2a892906192663f85030a6ab91304e508e546cddfe557d692d61ec57a1d946b";
};
propagatedBuildInputs = [ pytest ];
buildInputs = [ pytest ];
checkInputs = [ pytest ];

View File

@ -17,10 +17,11 @@ buildPythonPackage rec {
sha256 = "fb083925a17ce636f33997c275f61123e63372c1db11fefac1e991ed25a4ca37";
};
buildInputs = [ pytest ];
propagatedBuildInputs = [
six
numpy
pytest
];
checkInputs = [

View File

@ -21,10 +21,11 @@ buildPythonPackage rec {
sha256 = "0v6b4ly0p8nknpnp3f4dbslfsifzzjx2vv27rfylx04kzdhg4m9p";
};
buildInputs = [ pytest ];
propagatedBuildInputs = [
factory_boy
inflection
pytest
];
checkInputs = [

View File

@ -21,8 +21,9 @@ buildPythonPackage rec {
setuptools_scm
];
buildInputs = [ pytest ];
propagatedBuildInputs = [
pytest
pytest-doctestplus
pytestcov
pytestCheckHook

View File

@ -15,8 +15,9 @@ buildPythonPackage rec {
sha256 = "bf070c5485dad82d5b5f5d0eb08d269737e378492d9a68f5223b0a90924c7754";
};
buildInputs = [ pytest ];
propagatedBuildInputs = [ pyflakes ];
checkInputs = [ pytest ];
propagatedBuildInputs = [ pytest pyflakes ];
# no longer passes
doCheck = false;

View File

@ -12,8 +12,9 @@ buildPythonPackage rec {
doCheck = false;
buildInputs = [ pytest ];
propagatedBuildInputs = [
pytest
flask
werkzeug
];

View File

@ -18,9 +18,10 @@ buildPythonPackage rec {
sha256 = "10c4pbh03b4s1q8cjd75lr0fvyf9id0zmdk29566qqsmaz28npas";
};
buildInputs = [ pytest ];
propagatedBuildInputs = [
freezegun
pytest
];
checkInputs = [

View File

@ -12,7 +12,8 @@ buildPythonPackage rec {
};
nativeBuildInputs = [ setuptools_scm ];
propagatedBuildInputs = [ pytest pytest-metadata ];
buildInputs = [ pytest ];
propagatedBuildInputs = [ pytest-metadata ];
meta = with lib; {
description = "Plugin for generating HTML reports";

View File

@ -18,9 +18,10 @@ buildPythonPackage rec {
sha256 = "08idd3y6khxjqkn46diqvkjvsl4w4pxhl6z1hspbkrj0pqwf9isi";
};
buildInputs = [ pytest ];
propagatedBuildInputs = [
httpx
pytest
];
checkInputs = [

View File

@ -11,7 +11,7 @@ buildPythonPackage rec {
};
nativeBuildInputs = [ setuptools_scm ];
propagatedBuildInputs = [ pytest ];
buildInputs = [ pytest ];
meta = with lib; {
description = "Plugin for accessing test session metadata";

View File

@ -18,7 +18,9 @@ buildPythonPackage rec {
nativeBuildInputs = [ setuptools_scm ];
propagatedBuildInputs = [ pytest mypy filelock ];
buildInputs = [ pytest ];
propagatedBuildInputs = [ mypy filelock ];
# does not contain tests
doCheck = false;

View File

@ -20,8 +20,9 @@ buildPythonPackage rec {
nativeBuildInputs = [ setuptools_scm ];
buildInputs = [ pytest ];
propagatedBuildInputs = [
pytest
psutil
];

View File

@ -17,7 +17,7 @@ buildPythonPackage rec {
sha256 = "9c9e4f1b060414c642e88ad98ca60f1fd37937debd704bd8f4a2ef8e08b9cb6d";
};
propagatedBuildInputs = [ pytest ];
buildInputs = [ pytest ];
checkInputs = [
pytestCheckHook

View File

@ -21,8 +21,9 @@ buildPythonPackage rec {
nativeBuildInputs = [ pytestrunner ];
buildInputs = [ pytest ];
propagatedBuildInputs = [
pytest
pylint
six
toml

View File

@ -9,7 +9,7 @@ buildPythonPackage rec {
sha256 = "0qhxh0z2b3p52v3i0za9mrmjnb1nlvvyi2g23rf88b3xrrm59z33";
};
propagatedBuildInputs = [ pytest ];
buildInputs = [ pytest ];
checkInputs = [ pytest ];
checkPhase = ''

View File

@ -19,7 +19,7 @@ buildPythonPackage rec {
setuptools_scm
];
propagatedBuildInputs = [
buildInputs = [
pytest
];

View File

@ -16,7 +16,7 @@ buildPythonPackage rec {
disabled = pythonOlder "3.5";
propagatedBuildInputs = [ pytest ];
buildInputs = [ pytest ];
meta = with lib; {
homepage = "https://github.com/jbasko/pytest-random-order";

View File

@ -14,9 +14,10 @@ buildPythonPackage rec {
sha256 = "e20c58d4b7c359c4975dc3c3d3d67be0905180d2368be0be3ae09b15a136cfc0";
};
buildInputs = [ pytest ];
propagatedBuildInputs = [
six
pytest
];
checkInputs = [

View File

@ -11,9 +11,9 @@ buildPythonPackage rec {
sha256 = "1cb11a17fc121b3918414eb5eaf314ee325f2e693ac7cb3f6abf7560790827f2";
};
checkInputs = [ mock pytest ];
buildInputs = [ pytest ];
propagatedBuildInputs = [ pytest ];
checkInputs = [ mock pytest ];
checkPhase = ''
py.test test_pytest_rerunfailures.py

View File

@ -1,4 +1,5 @@
{ lib
, aiohttp
, async_generator
, buildPythonPackage
, doCheck ? true
@ -21,7 +22,10 @@ buildPythonPackage rec {
sha256 = "1zpgnw1lqbll59chv4hgcn31mdql1nv4gw9crbihky3ly3d3ncqi";
};
buildInputs = [ pytest ];
propagatedBuildInputs = [
aiohttp
async_generator
httpx
pytest

View File

@ -25,10 +25,11 @@ buildPythonPackage rec {
toml
];
buildInputs = [ pytest ];
propagatedBuildInputs = [
requests
psutil
pytest
zc_lockfile
] ++ lib.optional (!isPy3k) subprocess32;

View File

@ -11,9 +11,9 @@ buildPythonPackage rec {
sha256 = "0q8j0ayzmnvlraml6i977ybdq4xi096djhf30n2m1rvnvrhm45nq";
};
buildInputs = [ pytest ];
checkInputs = [ cmdline pytest ];
propagatedBuildInputs = [ pytestcov coverage setuptools-git mock pathpy execnet contextlib2 termcolor ];
nativeBuildInputs = [ pytest ];
checkPhase = ''
py.test ${lib.optionalString isPyPy "-k'not (test_run or test_run_integration)'"}

View File

@ -11,7 +11,9 @@ buildPythonPackage rec {
nativeBuildInputs = [ setuptools-scm ];
propagatedBuildInputs = [ packaging pytest ];
buildInputs = [ pytest ];
propagatedBuildInputs = [ packaging ];
# pypi does not contain tests and GitHub archive is not supported because setuptools-scm can't detect the version
doCheck = false;

View File

@ -15,7 +15,7 @@ buildPythonPackage rec {
sha256 = "1jbzkyp4xki81h01yl4vg3nrg9b6shsk1ryrmkaslffyhrqnj8zh";
};
propagatedBuildInputs = [
buildInputs = [
pytest
];

View File

@ -16,9 +16,10 @@ buildPythonPackage rec {
sha256 = "b1b2186b0a72aada6859bea2a5764145e3aaa2c1cfbb23c3a19b5f7b697563d3";
};
buildInputs = [ pytest ];
propagatedBuildInputs = [
termcolor
pytest
packaging
];

View File

@ -16,7 +16,7 @@ buildPythonPackage rec {
sha256 = "0xnsigs0kmpq1za0d4i522sp3f71x5bgpdh3ski0rs74yqy13cr0";
};
propagatedBuildInputs = [ pytest ];
buildInputs = [ pytest ];
checkInputs = [ pytestCheckHook pexpect pytestcov ];

View File

@ -17,7 +17,9 @@ buildPythonPackage rec {
# package has no tests
doCheck = false;
propagatedBuildInputs = [ pytest tornado ];
buildInputs = [ pytest ];
propagatedBuildInputs = [ tornado ];
meta = with lib; {
description = "A py.test plugin providing fixtures and markers to simplify testing of asynchronous tornado applications.";

View File

@ -15,8 +15,9 @@ buildPythonPackage rec {
sha256 = "04cg1cfrr55dbi8nljkpcsc103i5c6p0nr46vjr0bnxgkxx03x36";
};
buildInputs = [ pytest ];
propagatedBuildInputs = [
pytest
tornado
];

View File

@ -13,11 +13,12 @@ buildPythonPackage rec {
sha256 = "0bhh2nknhp14jzsx4zzpqm4qnfaihyi65cjf6kf6qgdhc0ax6nf4";
};
buildInputs = [ pytest ];
propagatedBuildInputs = [
trio
async_generator
outcome
pytest
];
checkInputs = [

View File

@ -16,7 +16,9 @@ buildPythonPackage rec {
sha256 = "cee2320becc5625050ab221b8f38533e636651a24644612f4726891fdf1f1847";
};
propagatedBuildInputs = [ greenlet pytest decorator ];
buildInputs = [ pytest ];
propagatedBuildInputs = [ greenlet decorator ];
meta = with lib; {
description = "A twisted plugin for py.test";

View File

@ -16,8 +16,9 @@ buildPythonPackage rec {
sha256 = "1i6fin91mklvbi8jzfiswvwf1m91f43smpj36a17xrzk4gisfs6i";
};
buildInputs = [ pytest ];
propagatedBuildInputs = [
pytest
vcrpy
];

View File

@ -9,7 +9,7 @@ buildPythonPackage rec {
sha256 = "5939f76fe04ad18297e53af0c9fb38aca1ec74db807bd40ad72733603adbbc7d";
};
propagatedBuildInputs = [ pytest ];
buildInputs = [ pytest ];
meta = {
description = "Plugin to list Python warnings in pytest report";

View File

@ -16,7 +16,9 @@ buildPythonPackage rec {
sha256 = "06136f03d5b361718b8d0d234042f7b2f203910d8568f63df2f866b547b3d4b9";
};
propagatedBuildInputs = [ pytest colorama docopt watchdog ];
buildInputs = [ pytest ];
propagatedBuildInputs = [ colorama docopt watchdog ];
# No Tests
doCheck = false;

View File

@ -14,7 +14,10 @@ buildPythonPackage rec {
};
nativeBuildInputs = [ setuptools_scm ];
propagatedBuildInputs = [ psutil pytest ];
buildInputs = [ pytest ];
propagatedBuildInputs = [ psutil ];
# Remove test QoL package from install_requires
postPatch = ''

View File

@ -16,8 +16,9 @@ buildPythonPackage rec {
sha256 = "1kyq5rg27dsnj7dc6x9y7r8vwf8rc88y2ppnnw6r96alw0nn9fn4";
};
buildInputs = [ pytest ];
propagatedBuildInputs = [
pytest
virtual-display
];