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

Pipeline fix #138

Merged
merged 8 commits into from
Oct 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
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
438 changes: 438 additions & 0 deletions .secrets.baseline

Large diffs are not rendered by default.

70 changes: 0 additions & 70 deletions .travis.yml

This file was deleted.

59 changes: 0 additions & 59 deletions .travis/build_and_test.sh

This file was deleted.

35 changes: 0 additions & 35 deletions .travis/build_env.sh

This file was deleted.

22 changes: 0 additions & 22 deletions .travis/get_vault_data.sh

This file was deleted.

29 changes: 0 additions & 29 deletions .travis/push_artifactory.sh

This file was deleted.

12 changes: 0 additions & 12 deletions .whitesource

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,10 @@
register: result
failed_when: false

- name: Debug result
ansible.builtin.debug:
msg: "{{ result }}"

- name: Assert 4 2.12
when: ansible_version.minor >= 12
ansible.builtin.assert:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,12 @@
failed_when: false
register: result

- name: Debug result
ansible.builtin.debug:
msg: "{{ result }}"

- name: Assert
ansible.builtin.assert:
that:
- result.failed is false
- '{{ "Error performing CMCI request: <urllib3.connection." in result.msg }}'
- '{{ "Name or service not known" in result.msg }}'
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
cmci_port: "{{ cmci_secure_port }}"
cmci_user: "{{ cmci_user }}"
cmci_password: "{{ cmci_password }}"

context: "{{ cmci_context }}"
scope: "{{ cmci_scope }}"
type: cicsprogram
Expand All @@ -42,7 +41,6 @@
cmci_port: "{{ cmci_port }}"
cmci_user: "{{ cmci_user }}"
cmci_password: "{{ cmci_password }}"

context: "{{ cmci_context }}"
scope: "{{ cmci_scope_region_1 }}"
type: cicsprogram
Expand All @@ -55,4 +53,4 @@
ansible.builtin.assert:
that:
- result.failed is false
- result.msg[:79] == 'Error performing CMCI request{{ ":" }} [SSL{{ ":" }} WRONG_VERSION_NUMBER] wrong version number'
- '{{ "Error performing CMCI request" in result.msg }}'
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@
# (c) Copyright IBM Corp. 2021,2024
# Apache License, Version 2.0 (see https://opensource.org/licenses/Apache-2.0)
set -eux # This is important to ensure that return codes from failing tests are propagated

if pip show requests 2>&1 | grep -q 'Package(s) not found'; then
ansible-playbook playbooks/cmci_missing_requests.yml
ansible-playbook playbooks/cmci_missing_requests.yml
else
CURRENT_PKG=$(pip freeze | grep requests=)
pip uninstall requests -y
ansible-playbook playbooks/cmci_missing_requests.yml
pip install "$CURRENT_PKG"
fi
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@
# (c) Copyright IBM Corp. 2021,2024
# Apache License, Version 2.0 (see https://opensource.org/licenses/Apache-2.0)
set -eux # This is important to ensure that return codes from failing tests are propagated

if pip show xmltodict 2>&1 | grep -q 'Package(s) not found'; then
ansible-playbook playbooks/cmci_missing_xmltodict.yml
fi
ansible-playbook playbooks/cmci_missing_xmltodict.yml
else
CURRENT_PKG=$(pip freeze | grep xmltodict=)
pip uninstall xmltodict -y
ansible-playbook playbooks/cmci_missing_xmltodict.yml
pip install "$CURRENT_PKG"
fi
11 changes: 9 additions & 2 deletions tests/integration/targets/cics_missing_zos_core/runme.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,12 @@ ZOS_ENV="$ANSIBLE_COLLECTIONS_PATH/ansible_collections/ibm/ibm_zos_cics/tests/in


if [ -z "$(ansible-galaxy collection list ibm.ibm_zos_core)" ]; then
ansible-playbook -i "$INV_PATH" -e "@$VAR_PATH" -e "@$ZOS_ENV" playbooks/missing_core.yml
fi
ansible-playbook -i "$INV_PATH" -e "@$VAR_PATH" -e "@$ZOS_ENV" playbooks/missing_core.yml
else
json_output=$(ansible-galaxy collection list ibm.ibm_zos_core --format json | jq -r)
collection_path=$(echo "$json_output" | jq -r 'keys[0]')
version=$(echo "$json_output" | jq -r .\""$collection_path"\".\"ibm.ibm_zos_core\".\"version\")
rm -r "$collection_path"/ibm/ibm_zos_core
ansible-playbook -i "$INV_PATH" -e "@$VAR_PATH" -e "@$ZOS_ENV" playbooks/missing_core.yml
ansible-galaxy collection install ibm.ibm_zos_core=="$version" -p"$collection_path"
fi
Loading
Loading