Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update integration test guide docker flag usage #1731

Merged
merged 2 commits into from
Aug 7, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/docsite/rst/dev_guide/testing_integration.rst
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ outside of those test subdirectories. They will also not reconfigure or bounce

.. note:: Running integration tests within containers

To protect your system from any potential changes caused by integration tests, and to ensure a sensible set of dependencies are available we recommend that you always run integration tests with the ``--docker`` option, for example ``--docker ubuntu2004``. See the `list of supported container images <https://github.com/ansible/ansible/blob/devel/test/lib/ansible_test/_data/completion/docker.txt>`_ for options (the ``default`` image is used for sanity and unit tests, as well as for platform independent integration tests such as those for cloud modules).
To protect your system from any potential changes caused by integration tests, and to ensure a sensible set of dependencies are available we recommend that you always run integration tests with the ``--docker`` option, for example ``--docker ubuntu2204``. Get the list of supported container images by running ``ansible-test integration --help`` (the ``default`` image is used for sanity and unit tests, as well as for platform independent integration tests such as those for cloud modules).
Copy link
Contributor Author

@MatthiasKunnen MatthiasKunnen Aug 6, 2024

Choose a reason for hiding this comment

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

Suggested change
To protect your system from any potential changes caused by integration tests, and to ensure a sensible set of dependencies are available we recommend that you always run integration tests with the ``--docker`` option, for example ``--docker ubuntu2204``. Get the list of supported container images by running ``ansible-test integration --help`` (the ``default`` image is used for sanity and unit tests, as well as for platform independent integration tests such as those for cloud modules).
To protect your system from any potential changes caused by integration tests, and to ensure a sensible set of dependencies are available we recommend that you always run integration tests with the ``--docker`` option, for example ``--docker ubuntu2204``. Get the list of supported container images by running ``ansible-test integration --help``. Look for *target docker images* (the ``default`` image is used for sanity and unit tests, as well as for platform independent integration tests such as those for cloud modules).

@oraNod, sorry for this late addition, I would add this part too, what do you think?
This is because the --help output is quite long and to avoid confusion with the controller docker images section.

Copy link
Contributor

Choose a reason for hiding this comment

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

@MatthiasKunnen No problem! That seems helpful to me. I would possibly rephrase it a little though.

Get the list of supported container images by running ``ansible-test integration --help``. You can find available images in the *target docker images* section of the output. The ``default`` image is used for sanity and unit tests, as well as for platform independent integration tests such as those for cloud modules.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I've committed a proposal

Copy link
Contributor

Choose a reason for hiding this comment

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

Thanks again @MatthiasKunnen That looks great.


Run as follows for all POSIX platform tests executed by our CI system in a Fedora 34 container:

Expand Down Expand Up @@ -245,4 +245,4 @@ Where to find out more
======================

If you'd like to know more about the plans for improving testing Ansible, join the
`Ansible community forum <https://forum.ansible.com/>`_
`Ansible community forum <https://forum.ansible.com/>`_
oraNod marked this conversation as resolved.
Show resolved Hide resolved