2ce5db779a
GitOrigin-RevId: 48037fd90426e44e4bf03e6479e88a11453b9b66
60 lines
1,006 B
Nix
60 lines
1,006 B
Nix
{ lib
|
|
, aioredis
|
|
, async_generator
|
|
, buildPythonPackage
|
|
, fetchPypi
|
|
, hypothesis
|
|
, lupa
|
|
, pytest-asyncio
|
|
, pytest-mock
|
|
, pytestCheckHook
|
|
, pythonOlder
|
|
, redis
|
|
, six
|
|
, sortedcontainers
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "fakeredis";
|
|
version = "1.7.5";
|
|
format = "pyproject";
|
|
|
|
disabled = pythonOlder "3.7";
|
|
|
|
src = fetchPypi {
|
|
inherit pname version;
|
|
hash = "sha256-STdcYwmB3UBF2akuJwn81Edskfkn4CKEk+76Yl5wUTM=";
|
|
};
|
|
|
|
postPatch = ''
|
|
substituteInPlace setup.cfg \
|
|
--replace "redis<4.2.0" "redis"
|
|
'';
|
|
|
|
propagatedBuildInputs = [
|
|
aioredis
|
|
lupa
|
|
redis
|
|
six
|
|
sortedcontainers
|
|
];
|
|
|
|
checkInputs = [
|
|
async_generator
|
|
hypothesis
|
|
pytest-asyncio
|
|
pytest-mock
|
|
pytestCheckHook
|
|
];
|
|
|
|
pythonImportsCheck = [
|
|
"fakeredis"
|
|
];
|
|
|
|
meta = with lib; {
|
|
description = "Fake implementation of Redis API";
|
|
homepage = "https://github.com/jamesls/fakeredis";
|
|
license = with licenses; [ mit ];
|
|
maintainers = with maintainers; [ fab ];
|
|
};
|
|
}
|