Loading pkgs/development/python-modules/pytest-ansible/default.nix +31 −15 Original line number Diff line number Diff line { lib, stdenv, ansible-compat, ansible-core, buildPythonPackage, coreutils, fetchFromGitHub, coreutils, # build-system setuptools, setuptools-scm, # dependencies ansible-compat, ansible-core, packaging, pytest, pytest-xdist, # buildInputs pytest, # tests pytestCheckHook, setuptools, setuptools-scm, writableTmpDirAsHomeHook, }: buildPythonPackage rec { buildPythonPackage (finalAttrs: { pname = "pytest-ansible"; version = "26.2.0"; pyproject = true; Loading @@ -22,7 +31,7 @@ buildPythonPackage rec { src = fetchFromGitHub { owner = "ansible"; repo = "pytest-ansible"; tag = "v${version}"; tag = "v${finalAttrs.version}"; hash = "sha256-3pppBAgAfkwJNPRsI6CH4UDMqyZ45+mFNejlQwX5bCg="; }; Loading @@ -45,11 +54,10 @@ buildPythonPackage rec { pytest-xdist ]; nativeCheckInputs = [ pytestCheckHook ]; preCheck = '' export HOME=$TMPDIR ''; nativeCheckInputs = [ pytestCheckHook writableTmpDirAsHomeHook ]; enabledTestPaths = [ "tests/" ]; Loading @@ -72,6 +80,14 @@ buildPythonPackage rec { disabledTestPaths = [ # Test want s to execute pytest in a subprocess "tests/integration/test_molecule.py" # TypeError: Cannot define type '_AnsibleLazyTemplateDict' since '_AnsibleLazyTemplateDict' # already extends '_AnsibleTaggedDict'. "tests/test_host_manager.py" # assert <ExitCode.TESTS_FAILED: 1> == <ExitCode.OK: 0> "tests/test_fixtures.py" "tests/test_params.py" ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ # These tests fail in the Darwin sandbox Loading @@ -88,10 +104,10 @@ buildPythonPackage rec { meta = { description = "Plugin for pytest to simplify calling ansible modules from tests or fixtures"; homepage = "https://github.com/jlaska/pytest-ansible"; changelog = "https://github.com/ansible-community/pytest-ansible/releases/tag/${src.tag}"; changelog = "https://github.com/ansible-community/pytest-ansible/releases/tag/${finalAttrs.src.tag}"; license = lib.licenses.mit; maintainers = with lib.maintainers; [ robsliwi ]; }; } }) Loading
pkgs/development/python-modules/pytest-ansible/default.nix +31 −15 Original line number Diff line number Diff line { lib, stdenv, ansible-compat, ansible-core, buildPythonPackage, coreutils, fetchFromGitHub, coreutils, # build-system setuptools, setuptools-scm, # dependencies ansible-compat, ansible-core, packaging, pytest, pytest-xdist, # buildInputs pytest, # tests pytestCheckHook, setuptools, setuptools-scm, writableTmpDirAsHomeHook, }: buildPythonPackage rec { buildPythonPackage (finalAttrs: { pname = "pytest-ansible"; version = "26.2.0"; pyproject = true; Loading @@ -22,7 +31,7 @@ buildPythonPackage rec { src = fetchFromGitHub { owner = "ansible"; repo = "pytest-ansible"; tag = "v${version}"; tag = "v${finalAttrs.version}"; hash = "sha256-3pppBAgAfkwJNPRsI6CH4UDMqyZ45+mFNejlQwX5bCg="; }; Loading @@ -45,11 +54,10 @@ buildPythonPackage rec { pytest-xdist ]; nativeCheckInputs = [ pytestCheckHook ]; preCheck = '' export HOME=$TMPDIR ''; nativeCheckInputs = [ pytestCheckHook writableTmpDirAsHomeHook ]; enabledTestPaths = [ "tests/" ]; Loading @@ -72,6 +80,14 @@ buildPythonPackage rec { disabledTestPaths = [ # Test want s to execute pytest in a subprocess "tests/integration/test_molecule.py" # TypeError: Cannot define type '_AnsibleLazyTemplateDict' since '_AnsibleLazyTemplateDict' # already extends '_AnsibleTaggedDict'. "tests/test_host_manager.py" # assert <ExitCode.TESTS_FAILED: 1> == <ExitCode.OK: 0> "tests/test_fixtures.py" "tests/test_params.py" ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ # These tests fail in the Darwin sandbox Loading @@ -88,10 +104,10 @@ buildPythonPackage rec { meta = { description = "Plugin for pytest to simplify calling ansible modules from tests or fixtures"; homepage = "https://github.com/jlaska/pytest-ansible"; changelog = "https://github.com/ansible-community/pytest-ansible/releases/tag/${src.tag}"; changelog = "https://github.com/ansible-community/pytest-ansible/releases/tag/${finalAttrs.src.tag}"; license = lib.licenses.mit; maintainers = with lib.maintainers; [ robsliwi ]; }; } })