Unverified Commit 254b7261 authored by natsukium's avatar natsukium
Browse files

python311Packages.mygpoclient: 1.8 -> 1.9

parent fcef8d5b
Loading
Loading
Loading
Loading
+17 −10
Original line number Diff line number Diff line
{
  lib,
  stdenv,
  fetchFromGitHub,
  buildPythonPackage,
  nose,
  setuptools,
  minimock,
  pytestCheckHook,
}:

buildPythonPackage rec {
  pname = "mypgoclient";
  version = "1.8";
  version = "1.9";
  pyproject = true;

  src = fetchFromGitHub {
    owner = "gpodder";
    repo = "mygpoclient";
    rev = version;
    sha256 = "0aa28wc55x3rxa7clwfv5v5500ffyaq0vkxaa3v01y1r93dxkdvp";
    hash = "sha256-McHllitWiBiCdNuJlUg6K/vgr2l3ychu+KOx3r/UCv0=";
  };

  postPatch = ''
    substituteInPlace mygpoclient/*_test.py \
      --replace-quiet "assertEquals" "assertEqual" \
      --replace-quiet "assert_" "assertTrue"
  '';

  build-system = [ setuptools ];

  pythonImportsCheck = [ "mygpoclient" ];

  nativeCheckInputs = [
    nose
    minimock
    pytestCheckHook
  ];

  checkPhase = ''
    nosetests
  '';

  doCheck = (!stdenv.isDarwin);
  __darwinAllowLocalNetworking = true;

  meta = with lib; {
    description = "Gpodder.net client library";