summary refs log tree commit diff
path: root/pkgs/development/python-modules/mwclient/default.nix
blob: bffc4247632d78f7a7e9859ac78234988a2dd6f8 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
{ lib, buildPythonPackage, fetchFromGitHub
, requests, requests_oauthlib, six
, pytest, pytestcache, pytest-cov, responses, mock
}:

buildPythonPackage rec {
  version = "0.10.1";
  pname = "mwclient";

  src = fetchFromGitHub {
    owner = "mwclient";
    repo = "mwclient";
    rev = "v${version}";
    sha256 = "120snnsh9n5svfwkyj1w9jrxf99jnqm0jk282yypd3lpyca1l9hj";
  };

  checkInputs = [ pytest pytestcache pytest-cov responses mock ];

  propagatedBuildInputs = [ requests requests_oauthlib six ];

  checkPhase = ''
    py.test
  '';

  meta = with lib; {
    description = "Python client library to the MediaWiki API";
    license = licenses.mit;
    homepage = "https://github.com/mwclient/mwclient";
  };
}