antsibull-nox 0.4.0__py3-none-any.whl → 0.5.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- antsibull_nox/__init__.py +1 -1
- antsibull_nox/config.py +1 -0
- antsibull_nox/data/action-groups.py +0 -1
- antsibull_nox/interpret_config.py +1 -0
- antsibull_nox/sessions/ansible_test.py +19 -4
- {antsibull_nox-0.4.0.dist-info → antsibull_nox-0.5.0.dist-info}/METADATA +1 -1
- {antsibull_nox-0.4.0.dist-info → antsibull_nox-0.5.0.dist-info}/RECORD +10 -10
- {antsibull_nox-0.4.0.dist-info → antsibull_nox-0.5.0.dist-info}/WHEEL +0 -0
- {antsibull_nox-0.4.0.dist-info → antsibull_nox-0.5.0.dist-info}/entry_points.txt +0 -0
- {antsibull_nox-0.4.0.dist-info → antsibull_nox-0.5.0.dist-info}/licenses/LICENSES/GPL-3.0-or-later.txt +0 -0
antsibull_nox/__init__.py
CHANGED
antsibull_nox/config.py
CHANGED
@@ -275,6 +275,7 @@ class SessionAnsibleTestIntegrationWDefaultContainer(_BaseModel):
|
|
275
275
|
except_versions: list[PAnsibleCoreVersion] = []
|
276
276
|
core_python_versions: dict[t.Union[PAnsibleCoreVersion, str], list[PVersion]] = {}
|
277
277
|
controller_python_versions_only: bool = False
|
278
|
+
ansible_vars_from_env_vars: dict[str, str] = {}
|
278
279
|
|
279
280
|
@p.model_validator(mode="after")
|
280
281
|
def _validate_core_keys(self) -> t.Self:
|
@@ -113,7 +113,6 @@ def scan(config: list[ActionGroup], errors: list[str]) -> None:
|
|
113
113
|
modules_directory = "plugins/modules/"
|
114
114
|
modules_suffix = ".py"
|
115
115
|
|
116
|
-
errors = []
|
117
116
|
for file in os.listdir(modules_directory):
|
118
117
|
if not file.endswith(modules_suffix):
|
119
118
|
continue
|
@@ -238,6 +238,7 @@ def _add_sessions(sessions: Sessions) -> None:
|
|
238
238
|
cfg.core_python_versions
|
239
239
|
),
|
240
240
|
controller_python_versions_only=cfg.controller_python_versions_only,
|
241
|
+
ansible_vars_from_env_vars=cfg.ansible_vars_from_env_vars,
|
241
242
|
)
|
242
243
|
if sessions.ansible_lint:
|
243
244
|
add_ansible_lint(
|
@@ -16,6 +16,7 @@ from collections.abc import Callable
|
|
16
16
|
from pathlib import Path
|
17
17
|
|
18
18
|
import nox
|
19
|
+
from antsibull_fileutils.yaml import store_yaml_file
|
19
20
|
|
20
21
|
from ..ansible import (
|
21
22
|
AnsibleCoreVersion,
|
@@ -168,7 +169,7 @@ def add_ansible_test_sanity_test_session(
|
|
168
169
|
"""
|
169
170
|
Add generic ansible-test sanity test session.
|
170
171
|
"""
|
171
|
-
command = ["sanity", "--
|
172
|
+
command = ["sanity", "--color", "-v", "--docker"]
|
172
173
|
if skip_tests:
|
173
174
|
for test in skip_tests:
|
174
175
|
command.extend(["--skip", test])
|
@@ -302,7 +303,7 @@ def add_ansible_test_unit_test_session(
|
|
302
303
|
add_ansible_test_session(
|
303
304
|
name=name,
|
304
305
|
description=description,
|
305
|
-
ansible_test_params=["units", "--
|
306
|
+
ansible_test_params=["units", "--color", "-v", "--docker"],
|
306
307
|
extra_deps_files=["tests/unit/requirements.yml"],
|
307
308
|
default=default,
|
308
309
|
ansible_core_version=ansible_core_version,
|
@@ -397,6 +398,7 @@ def add_ansible_test_integration_sessions_default_container(
|
|
397
398
|
dict[str | AnsibleCoreVersion, list[str | Version]] | None
|
398
399
|
) = None,
|
399
400
|
controller_python_versions_only: bool = False,
|
401
|
+
ansible_vars_from_env_vars: dict[str, str] | None = None,
|
400
402
|
default: bool = False,
|
401
403
|
) -> None:
|
402
404
|
"""
|
@@ -409,6 +411,18 @@ def add_ansible_test_integration_sessions_default_container(
|
|
409
411
|
controller Python versions.
|
410
412
|
"""
|
411
413
|
|
414
|
+
def callback_before() -> None:
|
415
|
+
if not ansible_vars_from_env_vars:
|
416
|
+
return
|
417
|
+
|
418
|
+
path = Path("tests", "integration", "integration_config.yml")
|
419
|
+
content: dict[str, t.Any] = {}
|
420
|
+
for ans_var, env_var in ansible_vars_from_env_vars.items():
|
421
|
+
value = os.environ.get(env_var)
|
422
|
+
if value is not None:
|
423
|
+
content[ans_var] = env_var
|
424
|
+
store_yaml_file(path, content, nice=True, sort_keys=True)
|
425
|
+
|
412
426
|
def add_integration_tests(
|
413
427
|
ansible_core_version: AnsibleCoreVersion,
|
414
428
|
repo_name: str | None = None,
|
@@ -459,10 +473,10 @@ def add_ansible_test_integration_sessions_default_container(
|
|
459
473
|
description=description,
|
460
474
|
ansible_test_params=[
|
461
475
|
"integration",
|
476
|
+
"--color",
|
477
|
+
"-v",
|
462
478
|
"--docker",
|
463
479
|
"default",
|
464
|
-
"-v",
|
465
|
-
"--color",
|
466
480
|
"--python",
|
467
481
|
str(py_version),
|
468
482
|
],
|
@@ -470,6 +484,7 @@ def add_ansible_test_integration_sessions_default_container(
|
|
470
484
|
ansible_core_version=ansible_core_version,
|
471
485
|
ansible_core_repo_name=repo_name,
|
472
486
|
ansible_core_branch_name=branch_name,
|
487
|
+
callback_before=callback_before,
|
473
488
|
default=False,
|
474
489
|
register_name="integration",
|
475
490
|
register_extra_data={
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: antsibull-nox
|
3
|
-
Version: 0.
|
3
|
+
Version: 0.5.0
|
4
4
|
Summary: Changelog tool for Ansible-core and Ansible collections
|
5
5
|
Project-URL: Documentation, https://ansible.readthedocs.io/projects/antsibull-nox/
|
6
6
|
Project-URL: Source code, https://github.com/ansible-community/antsibull-nox/
|
@@ -1,11 +1,11 @@
|
|
1
|
-
antsibull_nox/__init__.py,sha256=
|
1
|
+
antsibull_nox/__init__.py,sha256=fLhKsS6G8ngf77hrMr29GZp4IcLZusw_P-TW-QJ1SX8,845
|
2
2
|
antsibull_nox/_pydantic.py,sha256=VTIh-u0TpWvnY6Dhe4ba8nAmR2tYmz4PXNp2_8Sr9pw,3203
|
3
3
|
antsibull_nox/ansible.py,sha256=2EgaPK9ckS_KYTgpvb5HU9UOb6q5dpP3Az8sr1S7MU4,9346
|
4
4
|
antsibull_nox/cli.py,sha256=NKeRlWc_0taNRcZcdMv9LHZ5nCz8-DEJxBLPxJ9vFYQ,3358
|
5
|
-
antsibull_nox/config.py,sha256=
|
5
|
+
antsibull_nox/config.py,sha256=vuyq4m-IuIc7nHhQM5E7X8MN2DCOfW6UxOahZhOoX5Y,11089
|
6
6
|
antsibull_nox/data_util.py,sha256=7FVoqESEc-_QdqrQ16K1AHRVHEglNbRCH_mNaYDJ7a4,953
|
7
7
|
antsibull_nox/init.py,sha256=eRltIrS3AcHqEHk2yNAqJXv7kR6m_ysvFxIHpowd-2M,2259
|
8
|
-
antsibull_nox/interpret_config.py,sha256=
|
8
|
+
antsibull_nox/interpret_config.py,sha256=l2_yJ9G8Ls_JvMtJDdnuRL-ViPMy4XM3lPHXaR6giso,10915
|
9
9
|
antsibull_nox/lint_config.py,sha256=ZnsUbX6IdQK_IP9nvs8Kk6jb5lPdiREFSHAUuEGGceU,3848
|
10
10
|
antsibull_nox/paths.py,sha256=86HOynhCMTVop3ml_77JI06vM9nyK7PHMzLP_4M0V88,6317
|
11
11
|
antsibull_nox/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
@@ -16,7 +16,7 @@ antsibull_nox/collection/data.py,sha256=HmnASNuv97xFM08gYuQcAF3Nz6Oc6eXd5NN-wbMt
|
|
16
16
|
antsibull_nox/collection/extract.py,sha256=qNVknQRtRrCt10aawuU1Z6NTs16CA1bUEX3WDGBw68g,684
|
17
17
|
antsibull_nox/collection/install.py,sha256=xRXJ0kY8J1eOMmtHBZC6DqG38BF-RhjhvLF-GRT-Bb0,21622
|
18
18
|
antsibull_nox/collection/search.py,sha256=WZkcgNldl-feAqtKvn9fMMFxJ46kLeS0mqU-5R6yt7o,19296
|
19
|
-
antsibull_nox/data/action-groups.py,sha256=
|
19
|
+
antsibull_nox/data/action-groups.py,sha256=0rf5XfWU7sdoS7NyKHGNeWDkE5mFyN7p7IjHIuZYGw8,6918
|
20
20
|
antsibull_nox/data/antsibull-nox-lint-config.py,sha256=tXkKd9AqgfDs5w7S6OaBIt9HnT0KSbiQIU9tFxtYE2U,657
|
21
21
|
antsibull_nox/data/antsibull_nox_data_util.py,sha256=D4i_sKxjAeZuDV-z9Ibow0YYIqhXo2V_YC0LONLcEXM,2931
|
22
22
|
antsibull_nox/data/file-yamllint.py,sha256=hlS9tULwQSUMkdbYFfGtQGcPSj2scxEay6IalQfjSFE,3625
|
@@ -26,7 +26,7 @@ antsibull_nox/data/no-unwanted-files.py,sha256=_B3m-XWvWpdzGN-XAP8rLIS_5RMJGntFW
|
|
26
26
|
antsibull_nox/data/plugin-yamllint.py,sha256=bPIFmNwuTznaUjUhebccFa0IF_joyjIO7d3uF2HqjZQ,8466
|
27
27
|
antsibull_nox/sessions/__init__.py,sha256=4wTTO1E6rdCz4pVMuGUeuXi_vqFaH4whAL9qcjfOqto,2022
|
28
28
|
antsibull_nox/sessions/ansible_lint.py,sha256=ik2heGsvpRwYm_4XGwlm53UvWQ_7FHDWaBt7ttvUYbU,1661
|
29
|
-
antsibull_nox/sessions/ansible_test.py,sha256=
|
29
|
+
antsibull_nox/sessions/ansible_test.py,sha256=apHRgq8n2VDCEAce9wN6di9vM9ZNQKvXH4bhifefLvI,21006
|
30
30
|
antsibull_nox/sessions/build_import_check.py,sha256=kdr_Cqc0jb8XQQ-2QL-g_X7wgezE04oMVFCPr7a34iA,4719
|
31
31
|
antsibull_nox/sessions/collections.py,sha256=nhj_W2tbnsVJw6p7NkyP1xvmr3ZUmSJzwVuK0HE3oxw,4681
|
32
32
|
antsibull_nox/sessions/docs_check.py,sha256=mVYt278xy5AVwo5rCf6FLZlhqBiEYgJ3mmWsVBShKD0,2344
|
@@ -34,8 +34,8 @@ antsibull_nox/sessions/extra_checks.py,sha256=sBn0YFD8cM3OqeQ4UgYwD0NAcjKnYoy2zd
|
|
34
34
|
antsibull_nox/sessions/license_check.py,sha256=t5ut4ZluhFfk-qE6kcU8VNdvIGvzND81N7WCsbA4jLc,1824
|
35
35
|
antsibull_nox/sessions/lint.py,sha256=Idl3g3CB_zqlDbrCvItkjvYMw4TzbBcQWQnYLt5AL5Y,21639
|
36
36
|
antsibull_nox/sessions/utils.py,sha256=rrQdzmjdrLQula8t-BCTKbO-tAmzfOKHNn1pN2B1QVc,5632
|
37
|
-
antsibull_nox-0.
|
38
|
-
antsibull_nox-0.
|
39
|
-
antsibull_nox-0.
|
40
|
-
antsibull_nox-0.
|
41
|
-
antsibull_nox-0.
|
37
|
+
antsibull_nox-0.5.0.dist-info/METADATA,sha256=QcqWvDOeVpFEUzGOzBjRGLyMKExKgSHCJfSVsIW5E6U,7670
|
38
|
+
antsibull_nox-0.5.0.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
39
|
+
antsibull_nox-0.5.0.dist-info/entry_points.txt,sha256=solWA9TCB37UlaGk8sHXxJg-k1HWckfKdncHDBsVSsI,57
|
40
|
+
antsibull_nox-0.5.0.dist-info/licenses/LICENSES/GPL-3.0-or-later.txt,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
|
41
|
+
antsibull_nox-0.5.0.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|