diff --git a/pkgs/development/python-modules/pytest-qt/default.nix b/pkgs/development/python-modules/pytest-qt/default.nix new file mode 100644 index 000000000000..4ce0241f415b --- /dev/null +++ b/pkgs/development/python-modules/pytest-qt/default.nix @@ -0,0 +1,39 @@ +{ lib +, buildPythonPackage +, fetchPypi +, setuptools_scm +, pytest +, pyqt5 +}: + +buildPythonPackage rec { + pname = "pytest-qt"; + version = "3.2.2"; + + src = fetchPypi { + inherit pname version; + sha256 = "f6ecf4b38088ae1092cbd5beeaf714516d1f81f8938626a2eac546206cdfe7fa"; + }; + + nativeBuildInputs = [ + setuptools_scm + ]; + + propagatedBuildInputs = [ + pytest + ]; + + checkInputs = [ + pyqt5 + ]; + + # tests require X server + doCheck = false; + + meta = with lib; { + description = "pytest support for PyQt and PySide applications"; + homepage = "https://github.com/pytest-dev/pytest-qt"; + license = licenses.mit; + maintainers = with maintainers; [ costrouc ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 557a30df63df..1b7bd53802b9 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -1159,6 +1159,8 @@ in { pytest-pylint = callPackage ../development/python-modules/pytest-pylint { }; + pytest-qt = callPackage ../development/python-modules/pytest-qt { }; + pytest-testmon = callPackage ../development/python-modules/pytest-testmon { }; pytest-tornado = callPackage ../development/python-modules/pytest-tornado { };