From 13870b025a2729370f32b9145329243d9a0d7626 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sandro=20J=C3=A4ckel?= Date: Sat, 7 May 2022 03:28:21 +0200 Subject: [PATCH] python310Packages.m2r: adopt, run tests --- .../python-modules/m2r/default.nix | 23 +++++++++++++------ 1 file changed, 16 insertions(+), 7 deletions(-) diff --git a/pkgs/development/python-modules/m2r/default.nix b/pkgs/development/python-modules/m2r/default.nix index 35331c14b08..fd148382617 100644 --- a/pkgs/development/python-modules/m2r/default.nix +++ b/pkgs/development/python-modules/m2r/default.nix @@ -1,5 +1,11 @@ -{ lib, buildPythonPackage, fetchPypi, - mistune, docutils } : +{ lib +, buildPythonPackage +, fetchPypi +, docutils +, mistune +, pygments +}: + buildPythonPackage rec { pname = "m2r"; version = "0.2.1"; @@ -9,16 +15,19 @@ buildPythonPackage rec { sha256 = "bf90bad66cda1164b17e5ba4a037806d2443f2a4d5ddc9f6a5554a0322aaed99"; }; + postPatch = '' + substituteInPlace tests/test_cli.py \ + --replace "optional" "positional" + ''; + propagatedBuildInputs = [ mistune docutils ]; - # Some tests interfeere with each other (test.md and test.rst are - # deleted by some tests and not properly regenerated) - doCheck = false; + checkInputs = [ pygments ]; meta = with lib; { homepage = "https://github.com/miyakogi/m2r"; - description = "converts a markdown file including reST markups to a valid reST format"; + description = "Markdown to reStructuredText converter"; license = licenses.mit; - maintainers = [ ]; + maintainers = with maintainers; [ SuperSandro2000 ]; }; }