2017-09-26 17:31:57 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
, requests
|
|
|
|
, betamax
|
|
|
|
, mock
|
|
|
|
, pytest
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "requests-toolbelt";
|
2019-02-14 07:37:29 +00:00
|
|
|
version = "0.9.1";
|
2017-09-26 17:31:57 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2019-02-14 07:37:29 +00:00
|
|
|
sha256 = "968089d4584ad4ad7c171454f0a5c6dac23971e9472521ea3b6d49d610aa6fc0";
|
2017-09-26 17:31:57 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
checkInputs = [ betamax mock pytest ];
|
|
|
|
propagatedBuildInputs = [ requests ];
|
|
|
|
|
|
|
|
checkPhase = ''
|
2019-02-14 13:08:13 +00:00
|
|
|
# disabled tests access the network
|
|
|
|
py.test tests -k "not test_no_content_length_header \
|
|
|
|
and not test_read_file \
|
|
|
|
and not test_reads_file_from_url_wrapper"
|
2017-09-26 17:31:57 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "A toolbelt of useful classes and functions to be used with python-requests";
|
|
|
|
homepage = http://toolbelt.rtfd.org;
|
2019-02-14 13:09:55 +00:00
|
|
|
license = lib.licenses.asl20;
|
2019-02-20 18:52:48 +00:00
|
|
|
maintainers = with lib.maintainers; [ matthiasbeyer jgeerds ];
|
2017-09-26 17:31:57 +00:00
|
|
|
};
|
2019-02-20 18:52:48 +00:00
|
|
|
}
|