Skip to content

Conversation

@joelbreton2
Copy link
Contributor

@joelbreton2 joelbreton2 commented Oct 16, 2025

Change Summary

Change molecule testing structure to follow ansible-native configuration
Source

Related Issue(s)

Addresses part of #5990 - the second part (ansible-native)

Proposed changes

  • Modify molecule.yml in each test case with 'ansible-native' configuration

How to test

Local: run molecule test --scenario-name <scenario-name>
i.e. molecule test --scenario-name example-single-dc-l3ls

CI: Verify test results

Checklist

User Checklist

  • Verify eos_cli_config_gen_deprecated_vars is still required
  • Discuss destroy vs cleanup sequence

Repository Checklist

  • My code has been rebased from devel before I start
  • I have read the CONTRIBUTING document.
  • My change requires a change to the documentation and documentation have been updated accordingly.
  • I have updated molecule CI testing accordingly. (check the box if not applicable)

@joelbreton2 joelbreton2 requested review from a team as code owners October 16, 2025 13:47
@github-actions
Copy link

Review docs on Read the Docs

To test this pull request:

# Create virtual environment for this testing below the current directory
python -m venv test-avd-pr-6022
# Activate the virtual environment
source test-avd-pr-6022/bin/activate
# Install all requirements including PyAVD
pip install "pyavd[ansible] @ git+https://github.com/joelbreton2/avd.git@Test--make-molecule-ansible-native#subdirectory=python-avd" --force
# Point Ansible collections path to the Python virtual environment
export ANSIBLE_COLLECTIONS_PATH=$VIRTUAL_ENV/ansible_collections
# Install Ansible collection
ansible-galaxy collection install git+https://github.com/joelbreton2/avd.git#/ansible_collections/arista/avd/,Test--make-molecule-ansible-native --force
# Optional: Install AVD examples
cd test-avd-pr-6022
ansible-playbook arista.avd.install_examples

@github-actions github-actions bot added the state: CI Updated CI scenario have been updated in the PR label Oct 16, 2025
Copy link
Contributor

@gmuloc gmuloc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so these may be dumb questions, but:

1/ this looks like what I would have expected
2/ don't you need to add more stuff in my crappy empty default/molecule.yml? (maybe not :p )
3/ I am not sure where we rely on default and where not :)
4/ if some test_sequence don't make sense, don't hesitate to adjust them

Would be good to have some rationalization between all our examples :) some of them are (pre-)historical 🦣

backend: ansible-playbook
args:
ansible_playbook:
- --inventory=inventory/hosts.yml
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same maybe lets take the oppotrunity to rename the files the same in every scenario

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

removed the filename in the path, do you want me to renamed all inventory files to hosts.yml for the inventory.yml remaining?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lets align everything for our sanity

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All inventory files are now hosts.yml

@github-actions github-actions bot added the state: conflict PR with conflict label Oct 27, 2025
@github-actions
Copy link

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions github-actions bot removed the state: conflict PR with conflict label Oct 27, 2025
@github-actions
Copy link

Conflicts have been resolved. A maintainer will review the pull request shortly.

Copy link
Contributor

@gmuloc gmuloc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

as said in one comment let's use the same name for all inventory names

@sonarqubecloud
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

state: CI Updated CI scenario have been updated in the PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants