diff options
Diffstat (limited to 'nixpkgs/pkgs/development/python-modules/m3u8/default.nix')
-rw-r--r-- | nixpkgs/pkgs/development/python-modules/m3u8/default.nix | 26 |
1 files changed, 18 insertions, 8 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/m3u8/default.nix b/nixpkgs/pkgs/development/python-modules/m3u8/default.nix index decad482bef1..e69bf61657fa 100644 --- a/nixpkgs/pkgs/development/python-modules/m3u8/default.nix +++ b/nixpkgs/pkgs/development/python-modules/m3u8/default.nix @@ -1,24 +1,34 @@ -{ lib, buildPythonPackage, python, fetchFromGitHub, requests, iso8601, bottle, pytest, pytest-cov }: +{ lib, buildPythonPackage, fetchFromGitHub, fetchpatch, requests, iso8601, bottle, pytestCheckHook }: buildPythonPackage rec { pname = "m3u8"; - version = "0.6.0"; + version = "0.9.0"; src = fetchFromGitHub { owner = "globocom"; repo = pname; rev = version; - sha256 = "0cmg993icpsa1b19kljxvjwhs167bsqrs0ad4wnwsi8qq6na5d4p"; + sha256 = "sha256-EfHhmV2otEgEy2OVohS+DF7dk97GFdWZ4cFCERZBmlA="; }; - checkInputs = [ bottle pytest pytest-cov ]; - - checkPhase = '' - pytest tests/test_{parser,model,variant_m3u8}.py - ''; + patches = [ + # Fix hardcoded /tmp dir (fix build on Hydra) + (fetchpatch { + url = "https://github.com/globocom/m3u8/commit/cf7ae5fda4681efcea796cd7c51c02f152c36009.patch"; + sha256 = "sha256-SEETpIJQddid8D//6DVrSGs/BqDeMOzufE0bBrm+/xY="; + }) + ]; propagatedBuildInputs = [ requests iso8601 ]; + checkInputs = [ bottle pytestCheckHook ]; + + pytestFlagsArray = [ + "tests/test_parser.py" + "tests/test_model.py" + "tests/test_variant_m3u8.py" + ]; + meta = with lib; { homepage = "https://github.com/globocom/m3u8"; description = "Python m3u8 parser"; |