Unverified Commit a59f454d authored by Nick Cao's avatar Nick Cao Committed by GitHub
Browse files

python312Packages.numpydoc: cleanup and skip failing tests (#379945)

parents 12a098d8 a74399e7
Loading
Loading
Loading
Loading
+16 −13
Original line number Diff line number Diff line
@@ -2,13 +2,19 @@
  lib,
  buildPythonPackage,
  fetchPypi,
  isPy27,

  # build-system
  setuptools,

  # dependencies
  jinja2,
  sphinx,
  tabulate,
  pytestCheckHook,

  # tests
  matplotlib,
  pytest-cov-stub,
  pytestCheckHook,
}:

buildPythonPackage rec {
@@ -16,23 +22,15 @@ buildPythonPackage rec {
  version = "1.8.0";
  pyproject = true;

  disabled = isPy27;

  src = fetchPypi {
    inherit pname;
    inherit version;
    hash = "sha256-AiOQq3RkpE+HN/efizHOHTz6S0r3nMqhqsXoNo21h/s=";
  };

  postPatch = ''
    substituteInPlace pyproject.toml \
      --replace "--cov-report=" "" \
      --replace "--cov=numpydoc" ""
  '';
  build-system = [ setuptools ];

  nativeBuildInputs = [ setuptools ];

  propagatedBuildInputs = [
  dependencies = [
    jinja2
    sphinx
    tabulate
@@ -40,6 +38,7 @@ buildPythonPackage rec {

  nativeCheckInputs = [
    matplotlib
    pytest-cov-stub
    pytestCheckHook
  ];

@@ -47,7 +46,11 @@ buildPythonPackage rec {
    # https://github.com/numpy/numpydoc/issues/373
    "test_MyClass"
    "test_my_function"
    "test_reference"

    # AttributeError: 'MockApp' object has no attribute '_exception_on_warning'
    "test_mangle_docstring_validation_exclude"
    "test_mangle_docstring_validation_warnings"
    "test_mangle_docstrings_overrides"
  ];

  pythonImportsCheck = [ "numpydoc" ];