From 19484b9f57249977a3f2fc4200a5f492f9ba3f43 Mon Sep 17 00:00:00 2001 From: Martin Weinelt Date: Wed, 11 Nov 2020 19:57:31 +0100 Subject: [PATCH] pythonPackages.gtts-token: 1.1.3 -> 1.1.4 Enable checkPhase for the offline calculation test, disable the online test. --- .../python-modules/gtts-token/default.nix | 22 +++++++++++-------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/pkgs/development/python-modules/gtts-token/default.nix b/pkgs/development/python-modules/gtts-token/default.nix index d3443ef0c97..f3325aab8e6 100644 --- a/pkgs/development/python-modules/gtts-token/default.nix +++ b/pkgs/development/python-modules/gtts-token/default.nix @@ -1,31 +1,35 @@ { lib , buildPythonPackage -, fetchPypi +, fetchFromGitHub , requests +, pytestCheckHook }: buildPythonPackage rec { pname = "gtts-token"; - version = "1.1.3"; + version = "1.1.4"; - src = fetchPypi { - pname = "gTTS-token"; - inherit version; - sha256 = "9d6819a85b813f235397ef931ad4b680f03d843c9b2a9e74dd95175a4bc012c5"; + src = fetchFromGitHub { + owner = "boudewijn26"; + repo = "gTTS-token"; + rev = "v${version}"; + sha256 = "0vr52zc0jqyfvsccl67j1baims3cdx2is1y2lpx2kav9gadkn8hp"; }; propagatedBuildInputs = [ requests ]; - # Tests only in github repo, require working internet connection - doCheck = false; + checkInputs = [ pytestCheckHook ]; + + # requires internet access + disabledTests = [ "test_real" ]; meta = with lib; { description = "Calculates a token to run the Google Translate text to speech"; homepage = "https://github.com/boudewijn26/gTTS-token"; license = licenses.mit; - maintainers = [ maintainers.makefu ]; + maintainers = with maintainers; [ makefu ]; }; }