mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-10-21 04:42:07 +03:00
python310Packages.pyreadstat: enable tests
- add pythonImportsCheck - use module name
This commit is contained in:
parent
58bd31cfa1
commit
dbbb1e5ee4
@ -1,14 +1,26 @@
|
||||
{ lib, buildPythonPackage, fetchFromGitHub, cython, zlib, pandas, readstat }:
|
||||
{ lib
|
||||
, buildPythonPackage
|
||||
, cython
|
||||
, fetchFromGitHub
|
||||
, pandas
|
||||
, python
|
||||
, pythonOlder
|
||||
, readstat
|
||||
, zlib
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "pyreadstat";
|
||||
version = "1.1.9";
|
||||
format = "setuptools";
|
||||
|
||||
disabled = pythonOlder "3.7";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "Roche";
|
||||
repo = "pyreadstat";
|
||||
rev = "v${version}";
|
||||
sha256 = "16aa16ybh3ikmlxsg8zm19x9k6r4gpd0sxqagv318w76jjyw1nrs";
|
||||
hash = "sha256-OtvAvZTmcBTGfgp3Ddp9JJuZegr1o6c7rTMOuLwJSpk=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
@ -24,11 +36,26 @@ buildPythonPackage rec {
|
||||
pandas
|
||||
];
|
||||
|
||||
meta = {
|
||||
homepage = "https://github.com/Roche/pyreadstat";
|
||||
description = "Python package to read SAS, SPSS and Stata files into pandas data frames using the readstat C library";
|
||||
license = lib.licenses.asl20;
|
||||
maintainers = with lib.maintainers; [ swflint ];
|
||||
};
|
||||
pythonImportsCheck = [
|
||||
"pyreadstat"
|
||||
];
|
||||
|
||||
preCheck = ''
|
||||
export HOME=$(mktemp -d);
|
||||
'';
|
||||
|
||||
checkPhase = ''
|
||||
runHook preCheck
|
||||
|
||||
${python.interpreter} tests/test_basic.py
|
||||
|
||||
runHook postCheck
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Python package to read SAS, SPSS and Stata files into pandas data frames using the readstat C library";
|
||||
homepage = "https://github.com/Roche/pyreadstat";
|
||||
license = licenses.asl20;
|
||||
maintainers = with maintainers; [ swflint ];
|
||||
};
|
||||
}
|
||||
|
@ -8413,6 +8413,8 @@ in {
|
||||
|
||||
pyramid_multiauth = callPackage ../development/python-modules/pyramid_multiauth { };
|
||||
|
||||
pyreadstat = callPackage ../development/python-modules/pyreadstat { };
|
||||
|
||||
pyrealsense2 = toPythonModule (pkgs.librealsense.override {
|
||||
enablePython = true;
|
||||
pythonPackages = self;
|
||||
@ -9564,8 +9566,6 @@ in {
|
||||
|
||||
readme_renderer = callPackage ../development/python-modules/readme_renderer { };
|
||||
|
||||
readstats = callPackage ../development/python-modules/pyreadstat { };
|
||||
|
||||
readthedocs-sphinx-ext = callPackage ../development/python-modules/readthedocs-sphinx-ext { };
|
||||
|
||||
rebulk = callPackage ../development/python-modules/rebulk { };
|
||||
|
Loading…
Reference in New Issue
Block a user