2021-01-25 08:26:54 +00:00
|
|
|
{ lib
|
2021-12-04 21:20:57 +00:00
|
|
|
, stdenv
|
2018-10-28 15:24:29 +00:00
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
2022-03-02 21:42:28 +00:00
|
|
|
, flit-core
|
2021-06-19 01:19:05 +01:00
|
|
|
, pytestCheckHook
|
2018-10-28 15:24:29 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "testpath";
|
2022-03-02 21:42:28 +00:00
|
|
|
version = "0.6.0";
|
|
|
|
format = "pyproject";
|
2018-10-28 15:24:29 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
2021-06-19 00:46:01 +01:00
|
|
|
inherit pname version;
|
2022-03-02 21:42:28 +00:00
|
|
|
sha256 = "sha256-LxuX5kQsAmgevgG9hPUxAop8rqGvOCUAD1I0XDAoXg8=";
|
2018-10-28 15:24:29 +00:00
|
|
|
};
|
|
|
|
|
2022-03-02 21:42:28 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
flit-core
|
|
|
|
];
|
|
|
|
|
2021-06-19 01:19:05 +01:00
|
|
|
checkInputs = [
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
2021-12-04 21:20:57 +00:00
|
|
|
preCheck = lib.optionalString stdenv.isDarwin ''
|
|
|
|
# Work around https://github.com/jupyter/testpath/issues/24
|
|
|
|
export TMPDIR="/tmp"
|
|
|
|
'';
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2018-10-28 15:24:29 +00:00
|
|
|
description = "Test utilities for code working with files and commands";
|
|
|
|
license = licenses.mit;
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://github.com/jupyter/testpath";
|
2018-10-28 15:24:29 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
}
|