Commit 77aba030 authored by Fabian Affolter's avatar Fabian Affolter
Browse files

python312Packages.atomiclong: refactor

- migrate to pytestCheckHook
- update build-system
- add pythonImportsCheck
parent 27851edc
Loading
Loading
Loading
Loading
+27 −5
Original line number Diff line number Diff line
{ lib, buildPythonPackage, fetchPypi, pytest, cffi }:
{ lib
, buildPythonPackage
, cffi
, fetchPypi
, pytestCheckHook
, pythonOlder
, setuptools
}:

buildPythonPackage rec {
  pname = "atomiclong";
  version = "0.1.1";
  format = "setuptools";
  pyproject = true;

  disabled = pythonOlder "3.7";

  src = fetchPypi {
    inherit pname version;
    sha256 = "1gjbc9lvpkgg8vj7dspif1gz9aq4flkhxia16qj6yvb7rp27h4yb";
    hash = "sha256-yxN4xM1nbW8kNkHFDid1BKv0X3Dx6nbkRu/Nu2liS74=";
  };

  buildInputs = [ pytest ];
  propagatedBuildInputs = [ cffi ];
  build-system = [
    setuptools
  ];

  nativeCheckInputs = [
    pytestCheckHook
  ];

  dependencies = [
    cffi
  ];

  pythonImportsCheck = [
    "atomiclong"
  ];

  meta = with lib; {
    description = "Long data type with atomic operations using CFFI";