Merge pull request #56884 from kwohlfahrt/isort
pythonPackages.isort: 4.3.4 -> 4.3.15
This commit is contained in:
commit
4ad932483c
@ -1,4 +1,4 @@
|
||||
{ lib, buildPythonPackage, fetchPypi, tinycss2, pytest, pytestrunner, pytestcov, pytest-flake8, pytest-isort, glibcLocales }:
|
||||
{ lib, buildPythonPackage, fetchPypi, tinycss2, pytest, pytestrunner }:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "cssselect2";
|
||||
@ -9,11 +9,21 @@ buildPythonPackage rec {
|
||||
sha256 = "505d2ce3d3a1d390ddb52f7d0864b7efeb115a5b852a91861b498b92424503ab";
|
||||
};
|
||||
|
||||
# We're not interested in code quality tests
|
||||
postPatch = ''
|
||||
substituteInPlace setup.py \
|
||||
--replace "pytest-cov" "" \
|
||||
--replace "pytest-flake8" "" \
|
||||
--replace "pytest-isort" ""
|
||||
substituteInPlace setup.cfg \
|
||||
--replace "--cov=cssselect2" "" \
|
||||
--replace "--flake8" "" \
|
||||
--replace "--isort" ""
|
||||
'';
|
||||
|
||||
propagatedBuildInputs = [ tinycss2 ];
|
||||
|
||||
checkInputs = [ pytest pytestrunner pytestcov pytest-flake8 pytest-isort glibcLocales ];
|
||||
|
||||
LC_ALL = "en_US.UTF-8";
|
||||
checkInputs = [ pytest pytestrunner ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "CSS selectors for Python ElementTree";
|
||||
|
@ -1,22 +1,24 @@
|
||||
{ lib, buildPythonPackage, fetchPypi, isPy27, futures, mock, pytest }:
|
||||
{ lib, buildPythonPackage, fetchPypi, isPy27, futures, backports_functools_lru_cache, mock, pytest }:
|
||||
|
||||
buildPythonPackage rec {
|
||||
let
|
||||
skipTests = lib.optional isPy27 "test_standard_library_deprecates_user_issue_778";
|
||||
testOpts = lib.concatMapStringsSep " " (t: "--deselect test_isort.py::${t}") skipTests;
|
||||
in buildPythonPackage rec {
|
||||
pname = "isort";
|
||||
version = "4.3.4";
|
||||
version = "4.3.16"; # Note 4.x is the last version that supports Python2
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "1y0yfv56cqyh9wyg7kxxv9y5wmfgcq18n7a49mp7xmzka2bhxi5r";
|
||||
sha256 = "1v6lapqhc33rxr9698lqjyb49fis27i42p3ymngrw95py3qf7y08";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = lib.optional isPy27 futures;
|
||||
propagatedBuildInputs = lib.optionals isPy27 [ futures backports_functools_lru_cache ];
|
||||
|
||||
checkInputs = [ mock pytest ];
|
||||
|
||||
# isort excludes paths that contain /build/, so test fixtures don't work with TMPDIR=/build/
|
||||
checkPhase = ''
|
||||
py.test test_isort.py -k "not test_long_line_comments \
|
||||
and not test_import_case_produces_inconsistent_results_issue_472 \
|
||||
and not test_no_extra_lines_issue_557"
|
||||
PATH=$out/bin:$PATH TMPDIR=/tmp/ pytest ${testOpts}
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
|
Loading…
Reference in New Issue
Block a user