depot/third_party/nixpkgs/pkgs/development/python-modules/proton-vpn-connection/default.nix
Default email 159e378cbb Project import generated by Copybara.
GitOrigin-RevId: c04d5652cfa9742b1d519688f65d1bbccea9eb7e
2024-09-19 17:19:46 +03:00

67 lines
1.8 KiB
Nix

{
lib,
buildPythonPackage,
fetchFromGitHub,
setuptools,
proton-core,
proton-vpn-killswitch,
proton-vpn-logger,
jinja2,
pytestCheckHook,
pytest-cov-stub,
}:
buildPythonPackage rec {
pname = "proton-vpn-connection";
version = "0.14.4";
pyproject = true;
src = fetchFromGitHub {
owner = "ProtonVPN";
repo = "python-proton-vpn-connection";
rev = "refs/tags/v${version}";
hash = "sha256-Ze/te0G0tDzyZPGVVqvuJlZoHWJqJ36LnHO+Cy5nxx8=";
};
build-system = [ setuptools ];
dependencies = [
jinja2
proton-core
proton-vpn-killswitch
proton-vpn-logger
];
pythonImportsCheck = [ "proton.vpn.connection" ];
nativeCheckInputs = [
pytestCheckHook
pytest-cov-stub
];
disabledTests = [
# Permission denied: '/run'
"test_ensure_configuration_file_is_deleted"
"test_ensure_generate_is_returning_expected_content"
"test_ensure_same_configuration_file_in_case_of_duplicate"
"test_ensure_configuration_file_is_created"
"test_wireguard_config_content_generation"
"test_wireguard_with_malformed_credentials"
"test_wireguard_with_non_certificate"
"test_wireguard_without_settings"
# Neiter udp or tcp are working
"test_ovpnconfig_with_settings"
"test_ovpnconfig_with_missing_settings_applies_expected_defaults"
"test_ovpnconfig_with_malformed_params"
"test_ovpnconfig_with_certificate_and_malformed_credentials"
"test_ovpnconfig_with_malformed_server"
"test_ovpnconfig_with_malformed_server_and_credentials"
];
meta = {
description = "Defines the interface that VPN connection backends should implement";
homepage = "https://github.com/ProtonVPN/python-proton-vpn-connection";
license = lib.licenses.gpl3Only;
maintainers = with lib.maintainers; [ sebtm ];
};
}