Yueh-Shun Li 624897829b treewide: modernize Python package pytest flags
Use `(enabled|disabled)(TestPaths|TestMarks|Tests)` and `pytestFlags`
instead of the `__structuredAttrs`-incompatible `pytestFlagsArray`.
2025-07-15 03:00:08 +08:00

52 lines
820 B
Nix

{
buildPythonPackage,
isPy3k,
olm,
setuptools,
cffi,
aspectlib,
pytest-benchmark,
pytestCheckHook,
}:
buildPythonPackage {
pname = "python-olm";
inherit (olm) src version;
pyproject = true;
disabled = !isPy3k;
sourceRoot = "${olm.src.name}/python";
buildInputs = [ olm ];
preBuild = ''
make include/olm/olm.h
'';
build-system = [
setuptools
];
dependencies = [
cffi
];
propagatedNativeBuildInputs = [ cffi ];
pythonImportsCheck = [ "olm" ];
nativeCheckInputs = [
aspectlib
pytest-benchmark
pytestCheckHook
];
pytestFlags = [ "--benchmark-disable" ];
meta = {
inherit (olm.meta) license maintainers;
description = "Python bindings for Olm";
homepage = "https://gitlab.matrix.org/matrix-org/olm/tree/master/python";
};
}