diff --git a/infra/azure/azure-pipelines.yml b/infra/azure/azure-pipelines.yml index b4127fb3dc..0307817466 100644 --- a/infra/azure/azure-pipelines.yml +++ b/infra/azure/azure-pipelines.yml @@ -15,7 +15,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: fedora-latest + distro: fedora-latest ansible_version: "-core" filter_tests: false @@ -27,7 +27,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: fedora-latest + distro: fedora-latest ansible_version: "-core <2.14" filter_tests: false @@ -39,7 +39,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: fedora-latest + distro: fedora-latest ansible_version: "-core >=2.14,<2.15" filter_tests: false @@ -51,7 +51,7 @@ stages: - template: templates/galaxy_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: fedora-latest + distro: fedora-latest ansible_version: "-core >=2.14,<2.15" filter_tests: false @@ -63,7 +63,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: c9s + distro: c9s ansible_version: "-core >=2.14,<2.15" filter_tests: false @@ -75,6 +75,6 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: c8s + distro: c8s ansible_version: "-core >=2.14,<2.15" filter_tests: false diff --git a/infra/azure/nightly.yml b/infra/azure/nightly.yml index 3811c3cd7a..903638987d 100644 --- a/infra/azure/nightly.yml +++ b/infra/azure/nightly.yml @@ -22,7 +22,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: fedora-latest + distro: fedora-latest ansible_version: "-core >=2.13,<2.14" filter_tests: false @@ -32,7 +32,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: fedora-latest + distro: fedora-latest ansible_version: "-core >=2.14,<2.15" filter_tests: false @@ -42,7 +42,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: fedora-latest + distro: fedora-latest ansible_version: "-core >=2.15,<2.16" filter_tests: false @@ -52,7 +52,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: fedora-latest + distro: fedora-latest ansible_version: "" filter_tests: false @@ -64,7 +64,7 @@ stages: - template: templates/galaxy_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: fedora-latest + distro: fedora-latest ansible_version: "-core >=2.13,<2.14" filter_tests: false @@ -74,7 +74,7 @@ stages: - template: templates/galaxy_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: fedora-latest + distro: fedora-latest ansible_version: "-core >=2.14,<2.15" filter_tests: false @@ -84,7 +84,7 @@ stages: - template: templates/galaxy_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: fedora-latest + distro: fedora-latest ansible_version: "-core >=2.15,<2.16" filter_tests: false @@ -94,7 +94,7 @@ stages: - template: templates/galaxy_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: fedora-latest + distro: fedora-latest ansible_version: "" filter_tests: false @@ -106,7 +106,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: fedora-rawhide + distro: fedora-rawhide ansible_version: "-core >=2.13,<2.14" filter_tests: false @@ -116,7 +116,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: fedora-rawhide + distro: fedora-rawhide ansible_version: "-core >=2.14,<2.15" filter_tests: false @@ -126,7 +126,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: fedora-rawhide + distro: fedora-rawhide ansible_version: "-core >=2.15,<2.16" filter_tests: false @@ -136,7 +136,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: fedora-rawhide + distro: fedora-rawhide ansible_version: "" filter_tests: false @@ -148,7 +148,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: c9s + distro: c9s ansible_version: "-core >=2.13,<2.14" filter_tests: false @@ -158,7 +158,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: c9s + distro: c9s ansible_version: "-core >=2.14,<2.15" filter_tests: false @@ -168,7 +168,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: c9s + distro: c9s ansible_version: "-core >=2.15,<2.16" filter_tests: false @@ -178,7 +178,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: c9s + distro: c9s ansible_version: "" filter_tests: false @@ -190,7 +190,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: c8s + distro: c8s ansible_version: "-core >=2.13,<2.14" filter_tests: false @@ -200,7 +200,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: c8s + distro: c8s ansible_version: "-core >=2.14,<2.15" filter_tests: false @@ -210,7 +210,7 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: c8s + distro: c8s ansible_version: "-core >=2.15,<2.16" filter_tests: false @@ -220,6 +220,6 @@ stages: - template: templates/group_tests.yml parameters: build_number: $(Build.BuildNumber) - scenario: c8s + distro: c8s ansible_version: "" filter_tests: false diff --git a/infra/azure/templates/galaxy_pytest_script.yml b/infra/azure/templates/galaxy_pytest_script.yml deleted file mode 100644 index 3b16416961..0000000000 --- a/infra/azure/templates/galaxy_pytest_script.yml +++ /dev/null @@ -1,65 +0,0 @@ ---- -parameters: - - name: build_number - type: string - - name: scenario - type: string - default: fedora-latest - - name: ansible_version - type: string - default: "" - - name: python_version - type: string - default: 3.x - -jobs: -- job: Test_PyTests - displayName: Run pytests on ${{ parameters.scenario }} - timeoutInMinutes: 240 - steps: - - task: UsePythonVersion@0 - inputs: - versionSpec: '${{ parameters.python_version }}' - - - script: | - pip install \ - "molecule-plugins[docker]" \ - "requests<2.29" \ - "ansible${{ parameters.ansible_version }}" - retryCountOnTaskFailure: 5 - displayName: Install molecule and Ansible - - - script: ansible-galaxy collection install community.docker ansible.posix - retryCountOnTaskFailure: 5 - displayName: Install Ansible collections - - - script: pip install -r requirements-tests.txt - retryCountOnTaskFailure: 5 - displayName: Install dependencies - - - script: | - utils/build-galaxy-release.sh -i - molecule create -s ${{ parameters.scenario }} - retryCountOnTaskFailure: 5 - displayName: Setup test container - env: - ANSIBLE_LIBRARY: ./molecule - - - script: | - cd ~/.ansible/collections/ansible_collections/freeipa/ansible_freeipa - pytest \ - -m "not playbook" \ - --verbose \ - --color=yes \ - --junit-xml=TEST-results-pytests.xml - displayName: Run tests - env: - IPA_SERVER_HOST: ${{ parameters.scenario }} - RUN_TESTS_IN_DOCKER: true - IPA_VERBOSITY: "-vvv" - - - task: PublishTestResults@2 - inputs: - mergeTestResults: true - testRunTitle: PlaybookTests-Build${{ parameters.build_number }} - condition: succeededOrFailed() diff --git a/infra/azure/templates/galaxy_script.yml b/infra/azure/templates/galaxy_script.yml index a00dd0a55f..802c4cb259 100644 --- a/infra/azure/templates/galaxy_script.yml +++ b/infra/azure/templates/galaxy_script.yml @@ -6,7 +6,7 @@ parameters: - name: number_of_groups type: number default: 1 - - name: scenario + - name: distro type: string default: fedora-latest - name: ansible_version @@ -21,11 +21,11 @@ parameters: jobs: - job: Test_Group${{ parameters.group_number }} - displayName: Run playbook tests ${{ parameters.scenario }} (${{ parameters.group_number }}/${{ parameters.number_of_groups }}) + displayName: Run playbook tests ${{ parameters.distro }} (${{ parameters.group_number }}/${{ parameters.number_of_groups }}) timeoutInMinutes: 240 variables: - template: variables.yaml - - template: variables_${{ parameters.scenario }}.yaml + - template: variables_${{ parameters.distro }}.yaml steps: - task: UsePythonVersion@0 inputs: @@ -49,15 +49,15 @@ jobs: - script: | utils/build-galaxy-release.sh -i - molecule create -s ${{ parameters.scenario }} + molecule create -s ${{ parameters.distro }} retryCountOnTaskFailure: 5 displayName: Setup test container env: ANSIBLE_LIBRARY: ./molecule - script: | - python utils/check_test_configuration.py ${{ parameters.scenario }} - displayName: Check scenario test configuration + python utils/check_test_configuration.py ${{ parameters.distro }} + displayName: Check distro test configuration - script: | cd ~/.ansible/collections/ansible_collections/freeipa/ansible_freeipa @@ -71,7 +71,7 @@ jobs: --junit-xml=TEST-results-group-${{ parameters.group_number }}.xml displayName: Run playbook tests env: - IPA_SERVER_HOST: ${{ parameters.scenario }} + IPA_SERVER_HOST: ${{ parameters.distro }} RUN_TESTS_IN_DOCKER: true IPA_DISABLED_MODULES: ${{ variables.ipa_disabled_modules }} IPA_DISABLED_TESTS: ${{ variables.ipa_disabled_tests }} diff --git a/infra/azure/templates/galaxy_tests.yml b/infra/azure/templates/galaxy_tests.yml index 9464fba7ec..efbbefd958 100644 --- a/infra/azure/templates/galaxy_tests.yml +++ b/infra/azure/templates/galaxy_tests.yml @@ -1,6 +1,6 @@ --- parameters: - - name: scenario + - name: distro type: string default: fedora-latest - name: build_number @@ -15,7 +15,7 @@ jobs: group_number: 1 number_of_groups: 3 build_number: ${{ parameters.build_number }} - scenario: ${{ parameters.scenario }} + distro: ${{ parameters.distro }} ansible_version: ${{ parameters.ansible_version }} python_version: '< 3.12' @@ -24,7 +24,7 @@ jobs: group_number: 2 number_of_groups: 3 build_number: ${{ parameters.build_number }} - scenario: ${{ parameters.scenario }} + distro: ${{ parameters.distro }} ansible_version: ${{ parameters.ansible_version }} python_version: '< 3.12' @@ -33,17 +33,17 @@ jobs: group_number: 3 number_of_groups: 3 build_number: ${{ parameters.build_number }} - scenario: ${{ parameters.scenario }} + distro: ${{ parameters.distro }} ansible_version: ${{ parameters.ansible_version }} python_version: '< 3.12' # Temporarily disabled due to ansible docker plugin issue. -# - template: playbook_tests.yml +# - template: galaxy_script.yml # parameters: # group_number: 3 # number_of_groups: 3 # build_number: ${{ parameters.build_number }} -# scenario: ${{ parameters.scenario }} +# distro: ${{ parameters.distro }} # ansible_version: ${{ parameters.ansible_version }} # python_version: '< 3.12' # filter_tests: ${{ parameters.filter_tests }} diff --git a/infra/azure/templates/group_tests.yml b/infra/azure/templates/group_tests.yml index bab63efdcf..fd85ba4882 100644 --- a/infra/azure/templates/group_tests.yml +++ b/infra/azure/templates/group_tests.yml @@ -1,6 +1,6 @@ --- parameters: - - name: scenario + - name: distro type: string default: fedora-latest - name: build_number @@ -18,7 +18,7 @@ jobs: group_number: 1 number_of_groups: 3 build_number: ${{ parameters.build_number }} - scenario: ${{ parameters.scenario }} + distro: ${{ parameters.distro }} ansible_version: ${{ parameters.ansible_version }} python_version: '< 3.12' filter_tests: ${{ parameters.filter_tests }} @@ -28,7 +28,7 @@ jobs: group_number: 2 number_of_groups: 3 build_number: ${{ parameters.build_number }} - scenario: ${{ parameters.scenario }} + distro: ${{ parameters.distro }} ansible_version: ${{ parameters.ansible_version }} python_version: '< 3.12' filter_tests: ${{ parameters.filter_tests }} @@ -38,7 +38,7 @@ jobs: group_number: 3 number_of_groups: 3 build_number: ${{ parameters.build_number }} - scenario: ${{ parameters.scenario }} + distro: ${{ parameters.distro }} ansible_version: ${{ parameters.ansible_version }} python_version: '< 3.12' filter_tests: ${{ parameters.filter_tests }} @@ -49,7 +49,7 @@ jobs: # group_number: 3 # number_of_groups: 3 # build_number: ${{ parameters.build_number }} -# scenario: ${{ parameters.scenario }} +# distro: ${{ parameters.distro }} # ansible_version: ${{ parameters.ansible_version }} # python_version: '< 3.12' # filter_tests: ${{ parameters.filter_tests }}