diff options
Diffstat (limited to 'pkgs/development/python-modules/mayim/default.nix')
-rw-r--r-- | pkgs/development/python-modules/mayim/default.nix | 72 |
1 files changed, 34 insertions, 38 deletions
diff --git a/pkgs/development/python-modules/mayim/default.nix b/pkgs/development/python-modules/mayim/default.nix index 3cbc740aa458..44630b5121e4 100644 --- a/pkgs/development/python-modules/mayim/default.nix +++ b/pkgs/development/python-modules/mayim/default.nix @@ -1,17 +1,19 @@ -{ lib -, buildPythonPackage -, fetchFromGitHub -, setuptools -, wheel - -, psycopg -, aiosqlite -, asyncmy - -# test -, pytest-asyncio - -, pytestCheckHook +{ + lib, + buildPythonPackage, + fetchFromGitHub, + setuptools, + wheel, + + psycopg, + aiosqlite, + asyncmy, + + # test + pytest-asyncio, + pytest-cov-stub, + + pytestCheckHook, }: buildPythonPackage rec { @@ -26,36 +28,30 @@ buildPythonPackage rec { hash = "sha256-nb0E9kMEJUihaCp8RnqGh0nSyDQo50eL1C4K5lBPlPQ="; }; - nativeBuildInputs = [ + build-system = [ setuptools wheel ]; - postPatch = '' - substituteInPlace pyproject.toml \ - --replace "--cov=src --cov-append --cov-report term-missing" "" - ''; - - passthru.optional-dependencies = { - postgres = [ - psycopg - ] ++ psycopg.optional-dependencies.pool; - mysql = [ - asyncmy - ]; - sqlite = [ - aiosqlite - ]; + optional-dependencies = { + postgres = [ psycopg ] ++ psycopg.optional-dependencies.pool; + mysql = [ asyncmy ]; + sqlite = [ aiosqlite ]; }; - nativeCheckInputs = [ - pytestCheckHook - pytest-asyncio - ] ++ (with passthru.optional-dependencies; [postgres mysql sqlite]); - - pythonImportsCheck = [ - "mayim" - ]; + nativeCheckInputs = + [ + pytestCheckHook + pytest-asyncio + pytest-cov-stub + ] + ++ (with optional-dependencies; [ + postgres + mysql + sqlite + ]); + + pythonImportsCheck = [ "mayim" ]; meta = with lib; { description = "Asynchronous SQL hydrator"; |