From 4f7765794bfa378c0d97f287d684807f7ac64a3e Mon Sep 17 00:00:00 2001 From: Pyrox Date: Sun, 14 Jul 2024 21:34:02 -0400 Subject: [PATCH] python312Packages.ofxhome: remove nose and fix tests --- .../python-modules/ofxhome/default.nix | 31 ++++++++++++------- 1 file changed, 20 insertions(+), 11 deletions(-) diff --git a/pkgs/development/python-modules/ofxhome/default.nix b/pkgs/development/python-modules/ofxhome/default.nix index 7f4aa00dd213c..0110cfdba10dd 100644 --- a/pkgs/development/python-modules/ofxhome/default.nix +++ b/pkgs/development/python-modules/ofxhome/default.nix @@ -1,28 +1,37 @@ { lib, buildPythonPackage, - fetchPypi, - nose, + fetchFromGitHub, + pytestCheckHook, + setuptools, }: buildPythonPackage rec { version = "0.3.3"; - format = "setuptools"; pname = "ofxhome"; + pyproject = true; - src = fetchPypi { - inherit pname version; - sha256 = "1rpyfqr2q9pnin47rjd4qapl8ngk1m9jx36iqckhdhr8s8gla445"; + src = fetchFromGitHub { + owner = "captin411"; + repo = "ofxhome"; + rev = "v${version}"; + hash = "sha256-i16bE9iuafhAKco2jYfg5T5QCWFHdnYVztf1z2XbO9g="; }; - buildInputs = [ nose ]; + build-system = [ setuptools ]; - # ImportError: No module named tests - doCheck = false; + nativeCheckInputs = [ pytestCheckHook ]; - meta = with lib; { + # These are helper functions that should not be called as tests + disabledTests = [ + "testfile_name" + "testfile" + ]; + + meta = { homepage = "https://github.com/captin411/ofxhome"; description = "ofxhome.com financial institution lookup REST client"; - license = licenses.mit; + license = lib.licenses.mit; + maintainers = with lib.maintainers; [ pyrox0 ]; }; }