python3Packages.pytest-flask: cleanup, skip failing tests python>=3.14
This commit is contained in:
@@ -1,47 +1,71 @@
|
||||
{
|
||||
lib,
|
||||
stdenv,
|
||||
buildPythonPackage,
|
||||
fetchPypi,
|
||||
flask,
|
||||
pytest,
|
||||
pytestCheckHook,
|
||||
fetchFromGitHub,
|
||||
|
||||
# build-system
|
||||
setuptools-scm,
|
||||
|
||||
# buildInputs
|
||||
pytest,
|
||||
|
||||
# dependencies
|
||||
flask,
|
||||
werkzeug,
|
||||
|
||||
# tests
|
||||
pytestCheckHook,
|
||||
pythonAtLeast,
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
buildPythonPackage (finalAttrs: {
|
||||
pname = "pytest-flask";
|
||||
version = "1.3.0";
|
||||
format = "setuptools";
|
||||
pyproject = true;
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
hash = "sha256-WL4cl7Ibo8TUfgp2ketBAHdIUGw2v1EAT3jfEGkfqV4=";
|
||||
src = fetchFromGitHub {
|
||||
owner = "pytest-dev";
|
||||
repo = "pytest-flask";
|
||||
tag = finalAttrs.version;
|
||||
hash = "sha256-mcBHpP6A+ehqowDccfcn+wv6WXRrF0cY9ez7kqkb3Hc=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ setuptools-scm ];
|
||||
build-system = [ setuptools-scm ];
|
||||
|
||||
buildInputs = [ pytest ];
|
||||
|
||||
propagatedBuildInputs = [
|
||||
dependencies = [
|
||||
flask
|
||||
werkzeug
|
||||
];
|
||||
|
||||
nativeCheckInputs = [ pytestCheckHook ];
|
||||
|
||||
pythonImportsCheck = [ "pytest_flask" ];
|
||||
|
||||
disabledTestPaths = lib.optionals stdenv.hostPlatform.isDarwin [
|
||||
"tests/test_live_server.py"
|
||||
nativeCheckInputs = [ pytestCheckHook ];
|
||||
|
||||
disabledTests = lib.optionals (pythonAtLeast "3.14") [
|
||||
# Failed: nomatch: '*PASSED*'
|
||||
"test_add_endpoint_to_live_server"
|
||||
"test_clean_stop_live_server"
|
||||
"test_live_server_fixed_host"
|
||||
"test_live_server_fixed_port"
|
||||
"test_rewrite_application_server_name"
|
||||
"test_start_live_server"
|
||||
|
||||
# _pickle.PicklingError: Can't pickle local object
|
||||
"test_init"
|
||||
"test_server_is_alive"
|
||||
"test_server_listening"
|
||||
"test_set_application_server_name"
|
||||
"test_stop_cleanly_join_exception"
|
||||
"test_url_for"
|
||||
];
|
||||
|
||||
meta = {
|
||||
description = "Set of pytest fixtures to test Flask applications";
|
||||
homepage = "https://pytest-flask.readthedocs.io/";
|
||||
changelog = "https://github.com/pytest-dev/pytest-flask/blob/${version}/docs/changelog.rst";
|
||||
changelog = "https://github.com/pytest-dev/pytest-flask/blob/${finalAttrs.src.tag}/docs/changelog.rst";
|
||||
license = lib.licenses.mit;
|
||||
maintainers = with lib.maintainers; [ vanschelven ];
|
||||
};
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user