nixpkgs/pkgs/development/python-modules/pytoml/default.nix

35 lines
697 B
Nix
Raw Normal View History

{ lib
2017-12-31 09:52:37 +00:00
, buildPythonPackage
2019-04-04 10:03:15 +01:00
, fetchFromGitHub
2017-12-31 09:52:37 +00:00
, python
2019-04-04 10:03:15 +01:00
, pytest
2017-12-31 09:52:37 +00:00
}:
buildPythonPackage rec {
pname = "pytoml";
2019-04-04 10:03:15 +01:00
version = "0.1.20";
src = fetchFromGitHub {
owner = "avakar";
repo = "pytoml";
rev = "v${version}";
fetchSubmodules = true; # ensure test submodule is available
sha256 = "02hjq44zhh6z0fsbm3hvz34sav6fic90sjrw8g1pkdvskzzl46mz";
};
checkInputs = [ pytest ];
2017-12-31 09:52:37 +00:00
checkPhase = ''
${python.interpreter} test/test.py
2019-04-04 10:03:15 +01:00
pytest test
2017-12-31 09:52:37 +00:00
'';
meta = with lib; {
description = "A TOML parser/writer for Python";
homepage = "https://github.com/avakar/pytoml";
license = licenses.mit;
maintainers = with maintainers; [ peterhoeg ];
};
}