about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/okonomiyaki/default.nix
blob: c82b13cc2ee755f5914b5d9ed0892c239f041dac (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
{ buildPythonPackage
, stdenv
, fetchFromGitHub
, lib
, attrs
, distro
, jsonschema
, six
, zipfile2
, hypothesis
, mock
, packaging
, testfixtures
}:

buildPythonPackage rec {
  pname = "okonomiyaki";
  version = "1.4.0";

  src = fetchFromGitHub {
    owner = "enthought";
    repo = pname;
    rev = "refs/tags/${version}";
    hash = "sha256-MEll1H7l41m8uz2/WK/Ilm7Dubg0uqYwe+ZgakO1aXQ=";
  };

  propagatedBuildInputs = [ distro attrs jsonschema six zipfile2 ];

  preCheck = ''
    substituteInPlace okonomiyaki/runtimes/tests/test_runtime.py \
      --replace 'runtime_info = PythonRuntime.from_running_python()' 'raise unittest.SkipTest() #'
   '' + lib.optionalString stdenv.isDarwin ''
    substituteInPlace okonomiyaki/platforms/tests/test_pep425.py \
      --replace 'self.assertEqual(platform_tag, self.tag.platform)' 'raise unittest.SkipTest()'
  '';

  checkInputs = [ hypothesis mock packaging testfixtures ];

  pythonImportsCheck = [ "okonomiyaki" ];

  meta = with lib; {
    homepage = "https://github.com/enthought/okonomiyaki";
    description = "An experimental library aimed at consolidating a lot of low-level code used for Enthought's eggs";
    maintainers = with maintainers; [ genericnerdyusername ];
    license = licenses.bsd3;
  };
}