From a938c9de655823cac39328c1ecfb4a2651212d37 Mon Sep 17 00:00:00 2001
From: Felix Fontein <felix@fontein.de>
Date: Wed, 21 Sep 2022 07:58:52 +0200
Subject: [PATCH] Add stable-2.14 to CI, adjust to devel version bump (#5298)

* Add stable-2.14 to CI, adjust to devel version bump.

* Thin out matrix a bit.
---
 .azure-pipelines/azure-pipelines.yml | 78 +++++++++++++++++++++++++---
 .github/workflows/docs-pr.yml        |  5 +-
 README.md                            |  2 +-
 tests/sanity/ignore-2.15.txt         | 38 ++++++++++++++
 tests/sanity/ignore-2.15.txt.license |  3 ++
 5 files changed, 113 insertions(+), 13 deletions(-)
 create mode 100644 tests/sanity/ignore-2.15.txt
 create mode 100644 tests/sanity/ignore-2.15.txt.license

diff --git a/.azure-pipelines/azure-pipelines.yml b/.azure-pipelines/azure-pipelines.yml
index 60b9e31023..7daed5cb12 100644
--- a/.azure-pipelines/azure-pipelines.yml
+++ b/.azure-pipelines/azure-pipelines.yml
@@ -73,6 +73,19 @@ stages:
             - test: 3
             - test: 4
             - test: extra
+  - stage: Sanity_2_14
+    displayName: Sanity 2.14
+    dependsOn: []
+    jobs:
+      - template: templates/matrix.yml
+        parameters:
+          nameFormat: Test {0}
+          testFormat: 2.14/sanity/{0}
+          targets:
+            - test: 1
+            - test: 2
+            - test: 3
+            - test: 4
   - stage: Sanity_2_13
     displayName: Sanity 2.13
     dependsOn: []
@@ -129,6 +142,18 @@ stages:
             - test: 3.8
             - test: 3.9
             - test: '3.10'
+            - test: '3.11'
+  - stage: Units_2_14
+    displayName: Units 2.14
+    dependsOn: []
+    jobs:
+      - template: templates/matrix.yml
+        parameters:
+          nameFormat: Python {0}
+          testFormat: 2.14/units/{0}/1
+          targets:
+            - test: 2.7
+            - test: 3.9
   - stage: Units_2_13
     displayName: Units 2.13
     dependsOn: []
@@ -139,9 +164,7 @@ stages:
           testFormat: 2.13/units/{0}/1
           targets:
             - test: 2.7
-            - test: 3.6
             - test: 3.8
-            - test: 3.9
   - stage: Units_2_12
     displayName: Units 2.12
     dependsOn: []
@@ -152,7 +175,6 @@ stages:
           testFormat: 2.12/units/{0}/1
           targets:
             - test: 2.6
-            - test: 3.5
             - test: 3.8
   - stage: Units_2_11
     displayName: Units 2.11
@@ -163,11 +185,8 @@ stages:
           nameFormat: Python {0}
           testFormat: 2.11/units/{0}/1
           targets:
-            - test: 2.6
             - test: 2.7
             - test: 3.5
-            - test: 3.6
-            - test: 3.9
 
 ## Remote
   - stage: Remote_devel
@@ -192,6 +211,22 @@ stages:
             - 1
             - 2
             - 3
+  - stage: Remote_2_14
+    displayName: Remote 2.14
+    dependsOn: []
+    jobs:
+      - template: templates/matrix.yml
+        parameters:
+          testFormat: 2.14/{0}
+          targets:
+            - name: RHEL 9.0
+              test: rhel/9.0
+            - name: FreeBSD 13.1
+              test: freebsd/13.1
+          groups:
+            - 1
+            - 2
+            - 3
   - stage: Remote_2_13
     displayName: Remote 2.13
     dependsOn: []
@@ -238,8 +273,6 @@ stages:
               test: rhel/7.9
             - name: RHEL 8.3
               test: rhel/8.3
-            #- name: FreeBSD 12.2
-            #  test: freebsd/12.2
           groups:
             - 1
             - 2
@@ -270,6 +303,20 @@ stages:
             - 1
             - 2
             - 3
+  - stage: Docker_2_14
+    displayName: Docker 2.14
+    dependsOn: []
+    jobs:
+      - template: templates/matrix.yml
+        parameters:
+          testFormat: 2.14/linux/{0}
+          targets:
+            - name: Ubuntu 20.04
+              test: ubuntu2004
+          groups:
+            - 1
+            - 2
+            - 3
   - stage: Docker_2_13
     displayName: Docker 2.13
     dependsOn: []
@@ -356,6 +403,16 @@ stages:
           testFormat: devel/cloud/{0}/1
           targets:
             - test: 2.7
+            - test: '3.11'
+  - stage: Cloud_2_14
+    displayName: Cloud 2.14
+    dependsOn: []
+    jobs:
+      - template: templates/matrix.yml
+        parameters:
+          nameFormat: Python {0}
+          testFormat: 2.14/cloud/{0}/1
+          targets:
             - test: '3.10'
   - stage: Cloud_2_13
     displayName: Cloud 2.13
@@ -396,22 +453,27 @@ stages:
       - Sanity_2_11
       - Sanity_2_12
       - Sanity_2_13
+      - Sanity_2_14
       - Units_devel
       - Units_2_11
       - Units_2_12
       - Units_2_13
+      - Units_2_14
       - Remote_devel
       - Remote_2_11
       - Remote_2_12
       - Remote_2_13
+      - Remote_2_14
       - Docker_devel
       - Docker_2_11
       - Docker_2_12
       - Docker_2_13
+      - Docker_2_14
       - Docker_community_devel
       - Cloud_devel
       - Cloud_2_11
       - Cloud_2_12
       - Cloud_2_13
+      - Cloud_2_14
     jobs:
       - template: templates/coverage.yml
diff --git a/.github/workflows/docs-pr.yml b/.github/workflows/docs-pr.yml
index a3d5636ba5..0c2a70133a 100644
--- a/.github/workflows/docs-pr.yml
+++ b/.github/workflows/docs-pr.yml
@@ -24,10 +24,7 @@ jobs:
     uses: ansible-community/github-docs-build/.github/workflows/_shared-docs-build-pr.yml@main
     with:
       init-fail-on-error: true
-      # We need to use devel instead of stable-2.13 since stable-2.13's ansible-doc does not list
-      # modules. devel's ansible-doc does (thanks to the sidecar docs PR).
-      ansible-ref: devel
-      # ansible-ref: stable-2.13
+      ansible-ref: stable-2.14
       provide-link-targets: |
         ansible_collections.ansible.builtin.dict2items_filter
         ansible_collections.ansible.builtin.path_join_filter
diff --git a/README.md b/README.md
index d38a5653ec..94d5b506ba 100644
--- a/README.md
+++ b/README.md
@@ -23,7 +23,7 @@ If you encounter abusive behavior violating the [Ansible Code of Conduct](https:
 
 ## Tested with Ansible
 
-Tested with the current ansible-core 2.11, ansible-core 2.12, ansible-core 2.13 releases and the current development version of ansible-core. Ansible-core versions before 2.11.0 are not supported. This includes all ansible-base 2.10 and Ansible 2.9 releases.
+Tested with the current ansible-core 2.11, ansible-core 2.12, ansible-core 2.13, ansible-core 2.14 releases and the current development version of ansible-core. Ansible-core versions before 2.11.0 are not supported. This includes all ansible-base 2.10 and Ansible 2.9 releases.
 
 Parts of this collection will not work with ansible-core 2.11 on Python 3.12+.
 
diff --git a/tests/sanity/ignore-2.15.txt b/tests/sanity/ignore-2.15.txt
new file mode 100644
index 0000000000..a2ccf20db3
--- /dev/null
+++ b/tests/sanity/ignore-2.15.txt
@@ -0,0 +1,38 @@
+.azure-pipelines/scripts/publish-codecov.py replace-urlopen
+plugins/modules/cloud/univention/udm_user.py import-3.11  # Uses deprecated stdlib library 'crypt'
+plugins/modules/cloud/lxc/lxc_container.py use-argspec-type-path
+plugins/modules/cloud/lxc/lxc_container.py validate-modules:use-run-command-not-popen
+plugins/modules/cloud/lxd/lxd_project.py use-argspec-type-path # expanduser() applied to constants
+plugins/modules/cloud/misc/rhevm.py validate-modules:parameter-state-invalid-choice
+plugins/modules/cloud/rackspace/rax.py use-argspec-type-path # fix needed
+plugins/modules/cloud/rackspace/rax_files.py validate-modules:parameter-state-invalid-choice
+plugins/modules/cloud/rackspace/rax_files_objects.py use-argspec-type-path
+plugins/modules/cloud/rackspace/rax_scaling_group.py use-argspec-type-path  # fix needed, expanduser() applied to dict values
+plugins/modules/cloud/scaleway/scaleway_organization_info.py validate-modules:return-syntax-error
+plugins/modules/cloud/smartos/vmadm.py validate-modules:parameter-type-not-in-doc         # unused param - removed in 6.0.0
+plugins/modules/cloud/spotinst/spotinst_aws_elastigroup.py validate-modules:parameter-list-no-elements
+plugins/modules/cloud/spotinst/spotinst_aws_elastigroup.py validate-modules:parameter-type-not-in-doc
+plugins/modules/cloud/spotinst/spotinst_aws_elastigroup.py validate-modules:undocumented-parameter
+plugins/modules/cloud/univention/udm_share.py validate-modules:parameter-list-no-elements
+plugins/modules/cloud/univention/udm_user.py validate-modules:parameter-list-no-elements
+plugins/modules/clustering/consul/consul.py validate-modules:doc-missing-type
+plugins/modules/clustering/consul/consul.py validate-modules:undocumented-parameter
+plugins/modules/clustering/consul/consul_session.py validate-modules:parameter-state-invalid-choice
+plugins/modules/packaging/language/yarn.py use-argspec-type-path
+plugins/modules/packaging/os/redhat_subscription.py validate-modules:return-syntax-error
+plugins/modules/remote_management/manageiq/manageiq_policies.py validate-modules:parameter-state-invalid-choice
+plugins/modules/remote_management/manageiq/manageiq_provider.py validate-modules:doc-choices-do-not-match-spec   # missing docs on suboptions
+plugins/modules/remote_management/manageiq/manageiq_provider.py validate-modules:doc-missing-type                # missing docs on suboptions
+plugins/modules/remote_management/manageiq/manageiq_provider.py validate-modules:parameter-type-not-in-doc       # missing docs on suboptions
+plugins/modules/remote_management/manageiq/manageiq_provider.py validate-modules:undocumented-parameter          # missing docs on suboptions
+plugins/modules/remote_management/manageiq/manageiq_tags.py validate-modules:parameter-state-invalid-choice
+plugins/modules/system/gconftool2.py validate-modules:parameter-state-invalid-choice
+plugins/modules/system/homectl.py import-3.11  # Uses deprecated stdlib library 'crypt'
+plugins/modules/system/iptables_state.py validate-modules:undocumented-parameter
+plugins/modules/system/osx_defaults.py validate-modules:parameter-state-invalid-choice
+plugins/modules/system/parted.py validate-modules:parameter-state-invalid-choice
+plugins/modules/system/puppet.py use-argspec-type-path
+plugins/modules/system/puppet.py validate-modules:parameter-invalid  # invalid alias - removed in 7.0.0
+plugins/modules/system/ssh_config.py use-argspec-type-path # Required since module uses other methods to specify path
+plugins/modules/system/xfconf.py validate-modules:return-syntax-error
+plugins/modules/web_infrastructure/jenkins_plugin.py use-argspec-type-path
diff --git a/tests/sanity/ignore-2.15.txt.license b/tests/sanity/ignore-2.15.txt.license
new file mode 100644
index 0000000000..edff8c7685
--- /dev/null
+++ b/tests/sanity/ignore-2.15.txt.license
@@ -0,0 +1,3 @@
+GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
+SPDX-License-Identifier: GPL-3.0-or-later
+SPDX-FileCopyrightText: Ansible Project