python311Packages.jupyter-sphinx: enable tests

This commit is contained in:
natsukium
2024-01-04 11:11:49 +09:00
parent 9cd747bff4
commit 123996d440
@@ -1,6 +1,6 @@
{ lib
, buildPythonPackage
, fetchPypi
, fetchFromGitHub
, hatchling
, ipykernel
, ipython
@@ -9,6 +9,7 @@
, nbformat
, pythonOlder
, sphinx
, pytestCheckHook
}:
buildPythonPackage rec {
@@ -18,10 +19,11 @@ buildPythonPackage rec {
disabled = pythonOlder "3.8";
src = fetchPypi {
inherit version;
pname = "jupyter_sphinx";
hash = "sha256-LiNpmjoc9dsxsQmB2lqjJgbucw9rc6hE0edtgAdWr1Y=";
src = fetchFromGitHub {
owner = "jupyter";
repo = "jupyter-sphinx";
rev = "refs/tags/v${version}";
hash = "sha256-o/i3WravKZPf7uw2H4SVYfAyaZGf19ZJlkmeHCWcGtE=";
};
nativeBuildInputs = [
@@ -37,12 +39,26 @@ buildPythonPackage rec {
sphinx
];
doCheck = false;
pythonImportsCheck = [
"jupyter_sphinx"
];
env.JUPYTER_PLATFORM_DIRS = 1;
nativeCheckInputs = [
pytestCheckHook
];
preCheck = ''
export HOME=$TMPDIR
'';
__darwinAllowLocalNetworking = true;
meta = with lib; {
description = "Jupyter Sphinx Extensions";
homepage = "https://github.com/jupyter/jupyter-sphinx/";
changelog = "https://github.com/jupyter/jupyter-sphinx/releases/tag/${src.rev}";
license = licenses.bsd3;
};
}