mirror of
https://github.com/CHN-beta/nixpkgs.git
synced 2026-01-18 14:00:23 +08:00
checkInputs used to be added to nativeBuildInputs. Now we have nativeCheckInputs to do that instead. Doing this treewide change allows to keep hashes identical to before the introduction of nativeCheckInputs.
45 lines
988 B
Nix
45 lines
988 B
Nix
{ lib
|
|
, buildPythonPackage
|
|
, pythonOlder
|
|
, fetchFromGitHub
|
|
, webencodings
|
|
, pytestCheckHook
|
|
, flit-core
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "tinycss2";
|
|
version = "1.1.1";
|
|
format = "flit";
|
|
|
|
disabled = pythonOlder "3.6";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "kozea";
|
|
repo = "tinycss2";
|
|
rev = "v${version}";
|
|
# for tests
|
|
fetchSubmodules = true;
|
|
sha256 = "sha256-RUF/3cjNgDFofoxl9iKY3u5ZAVVQmXu2Qbb5U4brdcQ=";
|
|
};
|
|
|
|
postPatch = ''
|
|
substituteInPlace pyproject.toml \
|
|
--replace "'pytest-cov', 'pytest-flake8', 'pytest-isort', 'coverage[toml]'" "" \
|
|
--replace "--isort --flake8 --cov --no-cov-on-fail" ""
|
|
'';
|
|
|
|
nativeBuildInputs = [ flit-core ];
|
|
|
|
propagatedBuildInputs = [ webencodings ];
|
|
|
|
nativeCheckInputs = [ pytestCheckHook ];
|
|
|
|
meta = with lib; {
|
|
description = "Low-level CSS parser for Python";
|
|
homepage = "https://github.com/Kozea/tinycss2";
|
|
license = licenses.bsd3;
|
|
maintainers = with maintainers; [ onny ];
|
|
};
|
|
}
|