2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchFromGitHub,
|
|
|
|
hatchling,
|
|
|
|
pydantic,
|
|
|
|
pytest-examples,
|
|
|
|
pytestCheckHook,
|
|
|
|
pythonOlder,
|
|
|
|
pytz,
|
2022-06-16 17:23:12 +00:00
|
|
|
}:
|
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
let
|
|
|
|
dirty-equals = buildPythonPackage rec {
|
|
|
|
pname = "dirty-equals";
|
2024-01-13 08:15:51 +00:00
|
|
|
version = "0.7.1-post0";
|
2023-11-16 04:20:00 +00:00
|
|
|
format = "pyproject";
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.8";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "samuelcolvin";
|
|
|
|
repo = pname;
|
|
|
|
rev = "refs/tags/v${version}";
|
2024-01-13 08:15:51 +00:00
|
|
|
hash = "sha256-U6DNluthDgxzh6IOaKrN/JhX4u+ztY/jVp9IKh0iP34=";
|
2023-11-16 04:20:00 +00:00
|
|
|
};
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
nativeBuildInputs = [ hatchling ];
|
2023-11-16 04:20:00 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
propagatedBuildInputs = [ pytz ];
|
2023-11-16 04:20:00 +00:00
|
|
|
|
|
|
|
doCheck = false;
|
|
|
|
passthru.tests.pytest = dirty-equals.overrideAttrs { doCheck = true; };
|
|
|
|
|
|
|
|
nativeCheckInputs = [
|
|
|
|
pydantic
|
|
|
|
pytest-examples
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
pythonImportsCheck = [ "dirty_equals" ];
|
2023-11-16 04:20:00 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Module for doing dirty (but extremely useful) things with equals";
|
|
|
|
homepage = "https://github.com/samuelcolvin/dirty-equals";
|
|
|
|
changelog = "https://github.com/samuelcolvin/dirty-equals/releases/tag/v${version}";
|
|
|
|
license = with licenses; [ mit ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
2022-06-16 17:23:12 +00:00
|
|
|
};
|
2024-06-05 15:53:02 +00:00
|
|
|
in
|
|
|
|
dirty-equals
|