1{
2 lib,
3 buildPythonPackage,
4 fetchPypi,
5 hatch-vcs,
6 hatchling,
7 packaging,
8 pytestCheckHook,
9 pythonOlder,
10 pytz,
11 sentinels,
12}:
13
14buildPythonPackage rec {
15 pname = "mongomock";
16 version = "4.3.0";
17 pyproject = true;
18
19 disabled = pythonOlder "3.8";
20
21 src = fetchPypi {
22 inherit pname version;
23 hash = "sha256-MmZ7eQZvq8EtTxfxao/XNhtfRDUgizujLCJuUiEqjDA=";
24 };
25
26 build-system = [
27 hatch-vcs
28 hatchling
29 ];
30
31 dependencies = [
32 packaging
33 pytz
34 sentinels
35 ];
36
37 nativeCheckInputs = [ pytestCheckHook ];
38
39 pythonImportsCheck = [ "mongomock" ];
40
41 meta = with lib; {
42 description = "Fake pymongo stub for testing simple MongoDB-dependent code";
43 homepage = "https://github.com/mongomock/mongomock";
44 changelog = "https://github.com/mongomock/mongomock/blob/${version}/CHANGELOG.md";
45 license = licenses.bsd3;
46 maintainers = with maintainers; [ gador ];
47 };
48}