From 84a1c29c5ca8afbdf7ea9c8e30b2491728783ecb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Milan=20P=C3=A4ssler?= Date: Thu, 4 Feb 2021 21:54:15 +0100 Subject: [PATCH] python3Packages.pixelmatch: init at 0.2.2 --- .../python-modules/pixelmatch/default.nix | 38 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 40 insertions(+) create mode 100644 pkgs/development/python-modules/pixelmatch/default.nix diff --git a/pkgs/development/python-modules/pixelmatch/default.nix b/pkgs/development/python-modules/pixelmatch/default.nix new file mode 100644 index 000000000000..d7473a05bcca --- /dev/null +++ b/pkgs/development/python-modules/pixelmatch/default.nix @@ -0,0 +1,38 @@ +{ lib, buildPythonPackage, fetchgit, poetry-core, pytestCheckHook, pytest-benchmark, pytest-mypy, pillow }: + +buildPythonPackage rec { + pname = "pixelmatch"; + version = "0.2.2"; + format = "pyproject"; + + # test fixtures are stored in LFS + src = fetchgit { + url = "https://github.com/whtsky/pixelmatch-py"; + rev = "v${version}"; + sha256 = "1dsix507dxqik9wvgzscvf2pifbg7gx74krrsalqbfcmm7d1i7xl"; + fetchLFS = true; + }; + + nativeBuildInputs = [ + poetry-core + ]; + + checkInputs = [ + pytestCheckHook + pytest-benchmark + pytest-mypy + pillow + ]; + + pytestFlagsArray = [ + "--mypy" + "--benchmark-disable" + ]; + + meta = with lib; { + description = "A pixel-level image comparison library."; + homepage = "https://github.com/whtsky/pixelmatch-py"; + license = licenses.isc; + maintainers = with maintainers; [ petabyteboy ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 2e344fde7dff..743f6c45d679 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -4880,6 +4880,8 @@ in { inherit (pkgs.libsForQt5) soqt; }; + pixelmatch = callPackage ../development/python-modules/pixelmatch { }; + pkgconfig = callPackage ../development/python-modules/pkgconfig { inherit (pkgs) pkg-config; }; pkginfo = callPackage ../development/python-modules/pkginfo { };