summaryrefslogtreecommitdiff
path: root/pkgs/development/python-modules/mixbox/default.nix
blob: 1b01b64318ae7efe2e38f98f9e3b2ceddc848a0b (plain)
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
{
  lib,
  buildPythonPackage,
  fetchFromGitHub,
  lxml,
  ordered-set,
  pytestCheckHook,
  python-dateutil,
  setuptools,
}:

buildPythonPackage rec {
  pname = "mixbox";
  version = "1.0.5";
  pyproject = true;

  src = fetchFromGitHub {
    owner = "CybOXProject";
    repo = "mixbox";
    tag = "v${version}";
    hash = "sha256-qK3cKOf0s345M1pVFro5NFhDj4lch12UegOY1ZUEOBQ=";
  };

  build-system = [ setuptools ];

  dependencies = [
    lxml
    ordered-set
    python-dateutil
  ];

  nativeCheckInputs = [ pytestCheckHook ];

  pythonImportsCheck = [ "mixbox" ];

  enabledTestPaths = [ "test/*.py" ];

  disabledTests = [
    # Tests are out-dated
    "test_serialize_datetime_as_date"
    "test_preferred_prefixes"
  ];

  meta = {
    description = "Library of common code leveraged by cybox, maec and stix";
    homepage = "https://github.com/CybOXProject/mixbox";
    changelog = "https://github.com/CybOXProject/mixbox/releases/tag/v${version}";
    license = lib.licenses.bsd3;
    maintainers = with lib.maintainers; [ fab ];
  };
}