Merge pull request #129486 from mweinelt/python/pep8-naming
python3Packages.pep8-naming: fix tests
This commit is contained in:
commit
899ecadfc9
1 changed files with 25 additions and 4 deletions
|
@ -1,6 +1,10 @@
|
|||
{ lib, fetchPypi, buildPythonPackage, pythonOlder
|
||||
{ lib
|
||||
, fetchPypi
|
||||
, fetchpatch
|
||||
, buildPythonPackage
|
||||
, flake8
|
||||
, flake8-polyfill
|
||||
, importlib-metadata
|
||||
, python
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
|
@ -12,10 +16,27 @@ buildPythonPackage rec {
|
|||
sha256 = "0937rnk3c2z1jkdmbw9hfm80p5k467q7rqhn6slfiprs4kflgpd1";
|
||||
};
|
||||
|
||||
patches = [
|
||||
(fetchpatch {
|
||||
# Fix tests by setting extended-default-ignore to an empty list
|
||||
url = "https://github.com/PyCQA/pep8-naming/commit/6d62db81d7967e123e29673a4796fefec6f06d26.patch";
|
||||
sha256 = "1jpr2dga8sphksik3izyzq9hiszyki691mwnh2rjzd2vpgnv8cxf";
|
||||
})
|
||||
];
|
||||
|
||||
propagatedBuildInputs = [
|
||||
flake8
|
||||
flake8-polyfill
|
||||
] ++ lib.optionals (pythonOlder "3.8") [
|
||||
importlib-metadata
|
||||
];
|
||||
|
||||
checkPhase = ''
|
||||
runHook preCheck
|
||||
${python.interpreter} run_tests.py
|
||||
runHook postCheck
|
||||
'';
|
||||
|
||||
pythonImportsCheck = [
|
||||
"pep8ext_naming"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
|
|
Loading…
Reference in a new issue