Reduce warnings (#39254)

* removes FAQ links; no entries exist for linked config settings

* fixes various anchors and links

* addresses abadger comments, thanks

* marks orphan pages, avoids TOC errors

* adds links for remote_tmp setting to FAQ
This commit is contained in:
Alicia Cozine
2018-04-25 13:18:52 -05:00
committed by Toshio Kuratomi
parent 476d1f818e
commit 4b52a54e18
24 changed files with 65 additions and 47 deletions

View File

@@ -33,7 +33,7 @@ The following checklist items are important guidelines for people who want to c
'supported_by': 'community',
'metadata_version': '1.1'}
Read the complete :ref:`module metadata specification <ansible-metadata-block>` for more information.
Read the complete :ref:`module metadata specification <ansible_metadata_block>` for more information.
* Documentation: Make sure it exists
* Module documentation should briefly and accurately define what each module and option does, and how it works with others in the underlying system. Documentation should be written for broad audience--readable both by experts and non-experts. This documentation is not meant to teach a total novice, but it also should not be reserved for the Illuminati (hard balance).
@@ -100,7 +100,7 @@ Read the complete :ref:`module metadata specification <ansible-metadata-block>`
* Do not use wildcards for importing other python modules (ex: ``from ansible.module_utils.basic import *``). This used to be required for code imported from ``ansible.module_utils`` but, from Ansible-2.1 onwards, it's just an outdated and bad practice.
* The module must have a `main` function that wraps the normal execution.
* Call your :func:`main` from a conditional so that it would be possible to
import them into unittests in the future example
import them into unit tests in the future example
.. code-block:: python
@@ -119,8 +119,8 @@ Read the complete :ref:`module metadata specification <ansible-metadata-block>`
fields of a dictionary and return the dictionary.
* When fetching URLs, please use either fetch_url or open_url from ansible.module_utils.urls
rather than urllib2; urllib2 does not natively verify TLS certificates and so is insecure for https.
* facts modules must return facts in the ansible_facts field of the result
dictionary. :ref:`module_provided_facts`
* facts modules must return facts in the ansible_facts field of the :ref:`result
dictionary<common_return_values>`.
* modules that are purely about fact gathering need to implement check_mode.
they should not cause any changes anyway so it should be as simple as adding
check_mode=True when instantiating AnsibleModule. (The reason is that

View File

@@ -517,7 +517,7 @@ Why pass args over stdin?
Passing arguments via stdin was chosen for the following reasons:
* When combined with :ref:`pipelining`, this keeps the module's arguments from
* When combined with :ref:`ANSIBLE_PIPELINING`, this keeps the module's arguments from
temporarily being saved onto disk on the remote machine. This makes it
harder (but not impossible) for a malicious user on the remote machine to
steal any sensitive information that may be present in the arguments.

View File

@@ -1,3 +1,5 @@
.. _testing_running_locally:
***************
Testing Ansible
***************

View File

@@ -164,7 +164,7 @@ See `eos_banner test
for a practical example.
If you are simulating APIs you may find that python placebo is useful. See
doc:`testing_units_modules` for more information.
:ref:`testing_units_modules` for more information.
Code Coverage For New or Updated Unit Tests
@@ -189,13 +189,13 @@ Reports can be generated in several different formats:
* ``ansible-test coverage xml`` - XML report.
To clear data between test runs, use the ``ansible-test coverage erase`` command. See
:doc:`testing_units_running_locally` for more information about generating coverage
:ref:`testing_running_locally` for more information about generating coverage
reports.
.. seealso::
:doc:`testing_units_modules`
:ref:`testing_units_modules`
Special considerations for unit testing modules
:doc:`testing_running_locally`
Running tests locally including gathering and reporting coverage data

View File

@@ -1,3 +1,5 @@
.. _testing_units_modules:
****************************
Unit Testing Ansible Modules
****************************