Merge pull request #313626 from fabaff/tololib-darwin

python312Packages.tololib: disable tests on darwin
This commit is contained in:
Weijia Wang 2024-05-22 14:01:01 +02:00 committed by GitHub
commit 2e23d9d281
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1,10 +1,12 @@
{ lib
, buildPythonPackage
, fetchFromGitLab
, fetchpatch
, pytestCheckHook
, pythonOlder
, setuptools-scm
{
lib,
stdenv,
buildPythonPackage,
fetchFromGitLab,
fetchpatch,
pytestCheckHook,
pythonOlder,
setuptools-scm,
}:
buildPythonPackage rec {
@ -21,33 +23,25 @@ buildPythonPackage rec {
hash = "sha256-TxWKV2nrnCxZmj6+wBDMSdJRvKV+MsPFbOyIlUJYJ3Q=";
};
nativeBuildInputs = [
setuptools-scm
];
build-system = [ setuptools-scm ];
nativeCheckInputs = [
pytestCheckHook
];
nativeCheckInputs = [ pytestCheckHook ];
preCheck = ''
export PATH="$PATH:$out/bin";
'';
disabledTests = [
# Test requires network access
"test_discovery"
];
pythonImportsCheck = [ "tololib" ];
pythonImportsCheck = [
"tololib"
];
# Network discovery doesn't work in the sandbox for darwin
doCheck = !stdenv.isDarwin;
meta = with lib; {
description = "Python Library for Controlling TOLO Sauna/Steam Bath Devices";
mainProgram = "tolo-cli";
homepage = "https://gitlab.com/MatthiasLohr/tololib";
changelog = "https://gitlab.com/MatthiasLohr/tololib/-/blob/v${version}/CHANGELOG.md";
license = with licenses; [ mit ];
maintainers = with maintainers; [ fab ];
mainProgram = "tolo-cli";
};
}