about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/testbook/default.nix
blob: 331a7b61160c1271c7ca7cd71b3554960f040371 (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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
{ lib
, buildPythonPackage
, pythonOlder
, fetchFromGitHub
, nbformat
, nbclient
, ipykernel
, pandas
, pytestCheckHook
, setuptools
, traitlets
}:

buildPythonPackage rec {
  pname = "testbook";
  version = "0.4.2";
  format = "pyproject";

  disabled = pythonOlder "3.6";

  src = fetchFromGitHub {
    owner = "nteract";
    repo = pname;
    rev = version;
    hash = "sha256-qaDgae/5TRpjmjOf7aom7TC5HLHp0PHM/ds47AKtq8U=";
  };

  propagatedBuildInputs = [
    nbclient
    nbformat
  ];

  nativeBuildInputs = [
    setuptools
  ];

  nativeCheckInputs = [
    ipykernel
    pandas
    pytestCheckHook
    traitlets
  ];

  pythonImportsCheck = [
    "testbook"
  ];

  meta = with lib; {
    description = "A unit testing framework extension for testing code in Jupyter Notebooks";
    homepage = "https://testbook.readthedocs.io/";
    license = with licenses; [ bsd3 ];
    maintainers = with maintainers; [ djacu ];
  };
}