Skip to content

Commit

Permalink
fixup legacy pytest tests
Browse files Browse the repository at this point in the history
  • Loading branch information
gionn committed Nov 25, 2024
1 parent d300814 commit e6394e9
Show file tree
Hide file tree
Showing 10 changed files with 24 additions and 24 deletions.
4 changes: 2 additions & 2 deletions roles/activemq/molecule/default/tests/test_activemq.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ def get_ansible_vars(host):
"""Define get_ansible_vars"""
java_role = "file=../java/vars/main.yml name=java_role"
activemq_role = "file=../../vars/main.yml name=activemq_role"
common_vars = "file=../../../common/vars/main.yml name=common_vars"
common_defaults = "file=../../../common/defaults/main.yml name=common_defaults"
common_vars = "file=../../../../collections/alfresco/platform/roles/common/vars/main.yml name=common_vars"
common_defaults = "file=../../../../collections/alfresco/platform/roles/common/defaults/main.yml name=common_defaults"
group_vars = "file=../../../../group_vars/all.yml name=group_vars"
secrets_vars = "file=../../../../vars/secrets.yml name=secrets_vars"
ansible_vars = host.ansible("include_vars", java_role)["ansible_facts"]["java_role"]
Expand Down
4 changes: 2 additions & 2 deletions roles/java/molecule/default/tests/test_java.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
def get_ansible_vars(host):
"""Define get_ansible_vars"""
java_role = "file=../../vars/main.yml name=java_role"
common_vars = "file=../../../common/vars/main.yml name=common_vars"
common_defaults = "file=../../../common/defaults/main.yml name=common_defaults"
common_vars = "file=../../../../collections/alfresco/platform/roles/common/vars/main.yml name=common_vars"
common_defaults = "file=../../../../collections/alfresco/platform/roles/common/defaults/main.yml name=common_defaults"
group_vars = "file=../../../../group_vars/all.yml name=group_vars"
ansible_vars = host.ansible(
"include_vars",
Expand Down
4 changes: 2 additions & 2 deletions roles/nginx/molecule/default/tests/test_nginx.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
@pytest.fixture(scope="module")
def get_ansible_vars(host):
"""Define get_ansible_vars"""
common_vars = "file=../../../common/vars/main.yml name=common_vars"
common_defaults = "file=../../../common/defaults/main.yml name=common_defaults"
common_vars = "file=../../../../collections/alfresco/platform/roles/common/vars/main.yml name=common_vars"
common_defaults = "file=../../../../collections/alfresco/platform/roles/common/defaults/main.yml name=common_defaults"
nginx_vars = "file=../../vars/main.yml name=nginx_vars"
distribution_name = host.ansible("setup")["ansible_facts"]["ansible_distribution"]
distribution_version = host.ansible("setup")["ansible_facts"]["ansible_distribution_version"]
Expand Down
4 changes: 2 additions & 2 deletions roles/repository/molecule/default/tests/test_repository.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ def get_ansible_vars(host):
repository_role = "file=../../vars/main.yml name=repository_role"
tomcat_role = "file=../tomcat/vars/main.yml name=tomcat_role"
java_role = "file=../java/vars/main.yml name=java_role"
common_vars = "file=../../../common/vars/main.yml name=common_vars"
common_defaults = "file=../../../common/defaults/main.yml name=common_defaults"
common_vars = "file=../../../../collections/alfresco/platform/roles/common/vars/main.yml name=common_vars"
common_defaults = "file=../../../../collections/alfresco/platform/roles/common/defaults/main.yml name=common_defaults"
group_vars = "file=../../../../group_vars/all.yml name=group_vars"
ansible_vars = host.ansible("include_vars", group_vars)["ansible_facts"]["group_vars"]
ansible_vars.update(host.ansible("include_vars", common_defaults)["ansible_facts"]["common_defaults"])
Expand Down
6 changes: 3 additions & 3 deletions roles/search/molecule/default/tests/test_search.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@
def get_ansible_vars(host):
"""Define get_ansible_vars"""
java_role = "file=../java/vars/main.yml name=java_role"
common_vars = "file=../../../common/vars/main.yml name=common_vars"
common_defaults = "file=../../../common/defaults/main.yml name=common_defaults"
common_hosts = "file=../../../common/defaults/main.yml name=common_hosts"
common_vars = "file=../../../../collections/alfresco/platform/roles/common/vars/main.yml name=common_vars"
common_defaults = "file=../../../../collections/alfresco/platform/roles/common/defaults/main.yml name=common_defaults"
common_hosts = "file=../../../../collections/alfresco/platform/roles/common/defaults/main.yml name=common_hosts"
search_services = "file=../../vars/main.yml name=search_services"
ansible_vars = host.ansible("include_vars", java_role)["ansible_facts"]["java_role"]
ansible_vars.update(host.ansible("include_vars", java_role)["ansible_facts"]["java_role"])
Expand Down
6 changes: 3 additions & 3 deletions roles/sfs/molecule/default/tests/test_sfs.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@
def get_ansible_vars(host):
"""Define get_ansible_vars"""
java_role = "file=../roles/java/vars/main.yml name=java_role"
common_vars = "file=../../../common/vars/main.yml name=common_vars"
common_defaults = "file=../../../common/defaults/main.yml name=common_defaults"
common_hosts = "file=../../../common/vars/hosts.yml name=common_hosts"
common_vars = "file=../../../../collections/alfresco/platform/roles/common/vars/main.yml name=common_vars"
common_defaults = "file=../../../../collections/alfresco/platform/roles/common/defaults/main.yml name=common_defaults"
common_hosts = "file=../../../../collections/alfresco/platform/roles/common/vars/hosts.yml name=common_hosts"
ansible_vars = host.ansible("include_vars", java_role)["ansible_facts"]["java_role"]
ansible_vars.update(host.ansible("include_vars", common_vars)["ansible_facts"]["common_vars"])
ansible_vars.update(host.ansible("include_vars", common_hosts)["ansible_facts"]["common_hosts"])
Expand Down
4 changes: 2 additions & 2 deletions roles/sync/molecule/default/tests/test_sync.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
def get_ansible_vars(host):
"""Define get_ansible_vars"""
java_role = "file=../java/vars/main.yml name=java_role"
common_vars = "file=../../../common/vars/main.yml name=common_vars"
common_defaults = "file=../../../common/defaults/main.yml name=common_defaults"
common_vars = "file=../../../../collections/alfresco/platform/roles/common/vars/main.yml name=common_vars"
common_defaults = "file=../../../../collections/alfresco/platform/roles/common/defaults/main.yml name=common_defaults"
common_hosts = "file=../../../../group_vars/all.yml name=common_hosts"
syncservices = "file=../../vars/main.yml name=syncservices"
ansible_vars = host.ansible("include_vars", java_role)["ansible_facts"]["java_role"]
Expand Down
4 changes: 2 additions & 2 deletions roles/tomcat/molecule/default/tests/test_tomcat.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ def get_ansible_vars(host):
"""Define get_ansible_vars"""
java_role = "file=../java/vars/main.yml name=java_role"
tomcat_role = "file=../../vars/main.yml name=tomcat_role"
common_vars = "file=../../../common/vars/main.yml name=common_vars"
common_defaults = "file=../../../common/defaults/main.yml name=common_defaults"
common_vars = "file=../../../../collections/alfresco/platform/roles/common/vars/main.yml name=common_vars"
common_defaults = "file=../../../../collections/alfresco/platform/roles/common/defaults/main.yml name=common_defaults"
group_vars = "file=../../../../group_vars/all.yml name=group_vars"
ansible_vars = host.ansible("include_vars", java_role)["ansible_facts"]["java_role"]
ansible_vars.update(host.ansible("include_vars", tomcat_role)["ansible_facts"]["tomcat_role"])
Expand Down
6 changes: 3 additions & 3 deletions roles/transformers/molecule/default/tests/test_transform.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@
def get_ansible_vars(host):
"""Define get_ansible_vars"""
java_role = "file=../java/vars/main.yml name=java_role"
common_vars = "file=../../../common/vars/main.yml name=common_vars"
common_defaults = "file=../../../common/defaults/main.yml name=common_defaults"
common_hosts = "file=../../../common/vars/hosts.yml name=common_hosts"
common_vars = "file=../../../../collections/alfresco/platform/roles/common/vars/main.yml name=common_vars"
common_defaults = "file=../../../../collections/alfresco/platform/roles/common/defaults/main.yml name=common_defaults"
common_hosts = "file=../../../../collections/alfresco/platform/roles/common/vars/hosts.yml name=common_hosts"
transform_services = "file=../../vars/main.yml name=transform_services"
ansible_vars = host.ansible("include_vars", java_role)["ansible_facts"]["java_role"]
ansible_vars.update(host.ansible("include_vars", java_role)["ansible_facts"]["java_role"])
Expand Down
6 changes: 3 additions & 3 deletions roles/trouter/molecule/default/tests/test_trouter.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@
def get_ansible_vars(host):
"""Define get_ansible_vars"""
java_role = "file=../roles/java/vars/main.yml name=java_role"
common_vars = "file=../../../common/vars/main.yml name=common_vars"
common_defaults = "file=../../../common/defaults/main.yml name=common_defaults"
common_hosts = "file=../../../common/vars/hosts.yml name=common_hosts"
common_vars = "file=../../../../collections/alfresco/platform/roles/common/vars/main.yml name=common_vars"
common_defaults = "file=../../../../collections/alfresco/platform/roles/common/defaults/main.yml name=common_defaults"
common_hosts = "file=../../../../collections/alfresco/platform/roles/common/vars/hosts.yml name=common_hosts"
ansible_vars = host.ansible("include_vars", java_role)["ansible_facts"]["java_role"]
ansible_vars.update(host.ansible("include_vars", common_vars)["ansible_facts"]["common_vars"])
ansible_vars.update(host.ansible("include_vars", common_hosts)["ansible_facts"]["common_hosts"])
Expand Down

0 comments on commit e6394e9

Please sign in to comment.