nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 pythonAtLeast,
6 setuptools,
7}:
8
9buildPythonPackage {
10 pname = "assay";
11 version = "0-unstable-2024-05-09";
12 pyproject = true;
13
14 src = fetchFromGitHub {
15 owner = "brandon-rhodes";
16 repo = "assay";
17 rev = "74617d70e77afa09f58b3169cf496679ac5d5621";
18 hash = "sha256-zYpLtcXZ16EJWKSCqxFkSz/G9PwIZEQGBrYiJKuqnc4=";
19 };
20
21 build-system = [ setuptools ];
22
23 postPatch = lib.optionalString (pythonAtLeast "3.14") ''
24 substituteInPlace assay/assertion.py \
25 --replace-fail "op.load_assertion_error" "op.load_common_constant"
26 '';
27
28 pythonImportsCheck = [ "assay" ];
29
30 meta = {
31 homepage = "https://github.com/brandon-rhodes/assay";
32 description = "Attempt to write a Python testing framework I can actually stand";
33 license = lib.licenses.mit;
34 maintainers = with lib.maintainers; [ zane ];
35 };
36}