Browse Source

Clean up role tests

Now that we're using the general templates, we can slim down
the role test definitions. We can also remove tests which are
not being watched, or which are fundamentally broken. With
this we can also remove unused scripts/plays.

We do the following:

1. We remove the 'ssl' job, given that the person working on
   that is no longer doing so, and no-one else has picked up
   the work.
2. We remove the 'upgrade' job, given that it's been broken
   all cycle due to the way the job executes and we need to
   regroup to figure out another way to do it.
3. We promote the distro_install jobs, given that they are
   all now working.

Change-Id: I9d33daeb6d591c6919f131aafd62c4a33e4ff68f
Jesse Pretorius 7 months ago
parent
commit
221e1549ff

+ 0
- 4
tests/ansible-role-requirements.yml View File

@@ -50,10 +50,6 @@
50 50
   src: https://git.openstack.org/openstack/openstack-ansible-os_tempest
51 51
   scm: git
52 52
   version: master
53
-- name: os_previous_glance
54
-  src: https://git.openstack.org/openstack/openstack-ansible-os_glance
55
-  scm: git
56
-  version: stable/queens
57 53
 - name: systemd_service
58 54
   src: https://git.openstack.org/openstack/ansible-role-systemd_service
59 55
   scm: git

+ 0
- 28
tests/test-benchmark-glance-upgrade-results.yml View File

@@ -1,28 +0,0 @@
1
----
2
-# Copyright 2017, Rackspace US, Inc.
3
-#
4
-# Licensed under the Apache License, Version 2.0 (the "License");
5
-# you may not use this file except in compliance with the License.
6
-# You may obtain a copy of the License at
7
-#
8
-#     http://www.apache.org/licenses/LICENSE-2.0
9
-#
10
-# Unless required by applicable law or agreed to in writing, software
11
-# distributed under the License is distributed on an "AS IS" BASIS,
12
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
-# See the License for the specific language governing permissions and
14
-# limitations under the License.
15
-
16
-- name: Playbook to report resource tests
17
-  hosts: localhost
18
-  user: root
19
-  tasks:
20
-    - name: Kill resource test
21
-      command: pkill -f rolling_test
22
-    - name: Register upgrade benchmarking results
23
-      async_status: jid={{ rolling_test_benchmark.ansible_job_id }}
24
-      register: rolling_test_benchmark_results
25
-      until: rolling_test_benchmark_results.finished
26
-    - name: Display basic summary
27
-      debug:
28
-        msg: "Finished upgrade with {{ rolling_test_benchmark_results.stdout }}% API response failure rate"

+ 0
- 56
tests/test-benchmark-glance-upgrade.yml View File

@@ -1,56 +0,0 @@
1
----
2
-# Copyright 2017, Rackspace US, Inc.
3
-#
4
-# Licensed under the Apache License, Version 2.0 (the "License");
5
-# you may not use this file except in compliance with the License.
6
-# You may obtain a copy of the License at
7
-#
8
-#     http://www.apache.org/licenses/LICENSE-2.0
9
-#
10
-# Unless required by applicable law or agreed to in writing, software
11
-# distributed under the License is distributed on an "AS IS" BASIS,
12
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
-# See the License for the specific language governing permissions and
14
-# limitations under the License.
15
-
16
-- name: Playbook to run resource tests against an openstack service
17
-  hosts: localhost
18
-  user: root
19
-  become: true
20
-  # TODO: remove the static reference to openstack1
21
-  vars:
22
-    test_keystone_host: openstack1
23
-    working_dir: "{{ lookup('env', 'WORKING_DIR') }}"
24
-    upgrade_venv_folder: "/openstack/venvs/upgrades"
25
-    upgrade_test_packages:
26
-      - "python-keystoneclient"
27
-      - "python-glanceclient"
28
-      - "openstacksdk"
29
-  roles:
30
-    - openstack_openrc
31
-  post_tasks:
32
-    - name: Install openstack clients
33
-      pip:
34
-        name: "{{ upgrade_test_packages }}"
35
-        virtualenv: "{{ upgrade_venv_folder }}"
36
-        virtualenv_site_packages: "no"
37
-        extra_args: >-
38
-          {{ (pip_install_upper_constraints is defined) | ternary('--constraint ' + pip_install_upper_constraints | default(''),'') }}
39
-          {{ pip_install_options | default('') }}
40
-      register: install_packages
41
-      until: install_packages is success
42
-      retries: 5
43
-      delay: 2
44
-
45
-    - name: Run rolling test script
46
-      shell: |
47
-        source {{ upgrade_venv_folder }}/bin/activate
48
-        ./openstack-ansible-ops/bowling_ball/rolling_tests.py glance
49
-      args:
50
-        chdir: "{{ working_dir }}"
51
-        executable: /bin/bash
52
-      async: 100000
53
-      poll: 0
54
-      register: rolling_test_benchmark
55
-  vars_files:
56
-    - common/test-vars.yml

+ 0
- 104
tests/test-glance-upgrades.sh View File

@@ -1,104 +0,0 @@
1
-#!/usr/bin/env bash
2
-
3
-# Copyright 2016, Rackspace US, Inc.
4
-#
5
-# Licensed under the Apache License, Version 2.0 (the "License");
6
-# you may not use this file except in compliance with the License.
7
-# You may obtain a copy of the License at
8
-#
9
-#     http://www.apache.org/licenses/LICENSE-2.0
10
-#
11
-# Unless required by applicable law or agreed to in writing, software
12
-# distributed under the License is distributed on an "AS IS" BASIS,
13
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
-# See the License for the specific language governing permissions and
15
-# limitations under the License.
16
-
17
-# WARNING:
18
-# This file is use by all OpenStack-Ansible roles for testing purposes.
19
-# Any changes here will affect all OpenStack-Ansible role repositories
20
-# with immediate effect.
21
-
22
-# PURPOSE:
23
-# This script executes test Ansible playbooks required for performing
24
-# an upgrade test of the os_neutron role.
25
-# Due to the way Ansible caches and handles modules, we need to run
26
-# separate Ansible runs to ensure the "upgrade" uses the new
27
-# "neutron_migrations_facts" module, instead of the cached version
28
-# used when deploying the previous Neutron version.
29
-
30
-## Shell Opts ----------------------------------------------------------------
31
-
32
-set -e
33
-
34
-## Vars ----------------------------------------------------------------------
35
-
36
-export WORKING_DIR=${WORKING_DIR:-$(pwd)}
37
-export ROLE_NAME=${ROLE_NAME:-''}
38
-
39
-export ANSIBLE_PARAMETERS=${ANSIBLE_PARAMETERS:-"-vvv"}
40
-export TEST_PLAYBOOK=${TEST_PLAYBOOK:-$WORKING_DIR/tests/test-upgrade.yml}
41
-export TEST_CHECK_MODE=${TEST_CHECK_MODE:-false}
42
-export TEST_IDEMPOTENCE=${TEST_IDEMPOTENCE:-false}
43
-
44
-export COMMON_TESTS_PATH="${WORKING_DIR}/tests/common"
45
-export OSA_OPS_DIR="${WORKING_DIR}/openstack-ansible-ops"
46
-export BOWLING_BALL_DIR="${OSA_OPS_DIR}/bowling_ball"
47
-
48
-echo "ANSIBLE_OVERRIDES: ${ANSIBLE_OVERRIDES}"
49
-echo "ANSIBLE_PARAMETERS: ${ANSIBLE_PARAMETERS}"
50
-echo "TEST_PLAYBOOK: ${TEST_PLAYBOOK}"
51
-echo "TEST_CHECK_MODE: ${TEST_CHECK_MODE}"
52
-echo "TEST_IDEMPOTENCE: ${TEST_IDEMPOTENCE}"
53
-
54
-## Functions -----------------------------------------------------------------
55
-
56
-function execute_ansible_playbook {
57
-
58
-  export ANSIBLE_CLI_PARAMETERS="${ANSIBLE_PARAMETERS}"
59
-  export ANSIBLE_BIN=${ANSIBLE_BIN:-"ansible-playbook"}
60
-  CMD_TO_EXECUTE="${ANSIBLE_BIN}  ${TEST_PLAYBOOK} $@ ${ANSIBLE_CLI_PARAMETERS}"
61
-
62
-  echo "Executing: ${CMD_TO_EXECUTE}"
63
-  echo "With:"
64
-  echo "    ANSIBLE_INVENTORY: ${ANSIBLE_INVENTORY}"
65
-  echo "    ANSIBLE_LOG_PATH: ${ANSIBLE_LOG_PATH}"
66
-
67
-  ${CMD_TO_EXECUTE}
68
-
69
-}
70
-
71
-## Main ----------------------------------------------------------------------
72
-
73
-# Ensure that the Ansible environment is properly prepared
74
-source "${COMMON_TESTS_PATH}/test-ansible-env-prep.sh"
75
-
76
-# Prepare environment for the initial deploy of (previous and current) Glance
77
-# No upgrading or testing is done yet.
78
-export TEST_PLAYBOOK="${WORKING_DIR}/tests/test-upgrade.yml"
79
-export ANSIBLE_LOG_PATH="${ANSIBLE_LOG_DIR}/ansible-execute-glance-install.log"
80
-
81
-# Execute the setup of current infrastructure
82
-execute_ansible_playbook
83
-
84
-# Prepare environment for the deploy of previous glance:
85
-# No upgrading or testing is done yet.
86
-export TEST_PLAYBOOK="${WORKING_DIR}/tests/test-install-previous-glance.yml"
87
-export ANSIBLE_LOG_PATH="${ANSIBLE_LOG_DIR}/ansible-execute-previous_glance-install.log"
88
-export PREVIOUS_VENV="ansible-previous"
89
-export ANSIBLE_BIN="${WORKING_DIR}/.tox/${PREVIOUS_VENV}/bin/ansible-playbook"
90
-source ${COMMON_TESTS_PATH}/test-create-previous-venv.sh
91
-
92
-# Execute the setup of previous glance
93
-execute_ansible_playbook
94
-
95
-# Unset previous branch overrides
96
-unset PREVIOUS_VENV
97
-unset ANSIBLE_BIN
98
-
99
-# Prepare the environment for the upgrade of Glance
100
-export TEST_PLAYBOOK="${WORKING_DIR}/tests/test-upgrade-post.yml"
101
-export ANSIBLE_LOG_PATH="${ANSIBLE_LOG_DIR}/ansible-execute-glance-upgrade.log"
102
-
103
-# Execute the upgrade of Glance including testing/benchmarking
104
-execute_ansible_playbook

+ 0
- 34
tests/test-install-previous-glance.yml View File

@@ -1,34 +0,0 @@
1
----
2
-# Copyright 2016, Rackspace US, Inc.
3
-#
4
-# Licensed under the Apache License, Version 2.0 (the "License");
5
-# you may not use this file except in compliance with the License.
6
-# You may obtain a copy of the License at
7
-#
8
-#     http://www.apache.org/licenses/LICENSE-2.0
9
-#
10
-# Unless required by applicable law or agreed to in writing, software
11
-# distributed under the License is distributed on an "AS IS" BASIS,
12
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
-# See the License for the specific language governing permissions and
14
-# limitations under the License.
15
-
16
-# Ensure the repo is setup for previous version
17
-- include: common/previous/test-repo-setup.yml
18
-
19
-- name: Playbook for deploying glance
20
-  hosts: glance_all
21
-  user: root
22
-  gather_facts: true
23
-  pre_tasks:
24
-    - include: common/ensure-rabbitmq.yml
25
-      vhost_name: "{{ glance_rabbitmq_vhost }}"
26
-      user_name: "{{ glance_rabbitmq_userid }}"
27
-      user_password: "{{ glance_rabbitmq_password }}"
28
-    - include: common/create-grant-db.yml
29
-      db_name: "{{  glance_galera_database }}"
30
-      db_password: "{{ glance_container_mysql_password }}"
31
-  roles:
32
-    - role: "os_previous_glance"
33
-  vars_files:
34
-    - common/previous/test-vars.yml

+ 0
- 29
tests/test-upgrade-post.yml View File

@@ -1,29 +0,0 @@
1
----
2
-# Copyright 2017, Rackspace US, Inc.
3
-#
4
-# Licensed under the Apache License, Version 2.0 (the "License");
5
-# you may not use this file except in compliance with the License.
6
-# You may obtain a copy of the License at
7
-#
8
-#     http://www.apache.org/licenses/LICENSE-2.0
9
-#
10
-# Unless required by applicable law or agreed to in writing, software
11
-# distributed under the License is distributed on an "AS IS" BASIS,
12
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
-# See the License for the specific language governing permissions and
14
-# limitations under the License.
15
-
16
-# This playbook handles the installation of current Glance
17
-# Benchmarking, and tempest testing.
18
-
19
-# Install upgrade benchmarking
20
-- include: test-benchmark-glance-upgrade.yml
21
-
22
-# Install Glance
23
-- include: common/test-install-glance.yml
24
-
25
-# Install and execute Tempest
26
-- include: common/test-install-tempest.yml
27
-
28
-# Test upgrade benchmarking results
29
-- include: test-benchmark-glance-upgrade-results.yml

+ 0
- 23
tests/test-upgrade.yml View File

@@ -1,23 +0,0 @@
1
----
2
-# Copyright 2015, Rackspace US, Inc.
3
-#
4
-# Licensed under the Apache License, Version 2.0 (the "License");
5
-# you may not use this file except in compliance with the License.
6
-# You may obtain a copy of the License at
7
-#
8
-#     http://www.apache.org/licenses/LICENSE-2.0
9
-#
10
-# Unless required by applicable law or agreed to in writing, software
11
-# distributed under the License is distributed on an "AS IS" BASIS,
12
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
-# See the License for the specific language governing permissions and
14
-# limitations under the License.
15
-
16
-# Setup the host
17
-- include: common/test-setup-host.yml
18
-
19
-# Install RabbitMQ/MariaDB
20
-- include: common/test-install-infra.yml
21
-
22
-# Install Keystone
23
-- include: common/test-install-keystone.yml

+ 0
- 16
tox.ini View File

@@ -100,14 +100,6 @@ commands =
100 100
     bash -c "{toxinidir}/tests/common/test-ansible-functional.sh"
101 101
 
102 102
 
103
-[testenv:upgrade]
104
-setenv =
105
-    {[testenv]setenv}
106
-    CLONE_UPGRADE_TESTS=yes
107
-commands =
108
-    bash -c "{toxinidir}/tests/test-glance-upgrades.sh"
109
-
110
-
111 103
 [testenv:v2_registry_enabled]
112 104
 setenv =
113 105
     {[testenv]setenv}
@@ -125,14 +117,6 @@ commands =
125 117
     bash -c "{toxinidir}/tests/common/test-ansible-functional.sh"
126 118
 
127 119
 
128
-[testenv:ssl]
129
-setenv =
130
-    {[testenv]setenv}
131
-    ANSIBLE_PARAMETERS=-vvv -e galera_use_ssl=True
132
-commands =
133
-    bash -c "{toxinidir}/tests/common/test-ansible-functional.sh"
134
-
135
-
136 120
 [testenv:linters]
137 121
 commands =
138 122
     bash -c "{toxinidir}/tests/common/test-ansible-env-prep.sh"

+ 0
- 7
zuul.d/jobs.yaml View File

@@ -26,10 +26,3 @@
26 26
     nodeset: ubuntu-xenial
27 27
     vars:
28 28
       tox_env: nfs
29
-
30
-- job:
31
-    name: openstack-ansible-glance-ssl-nv
32
-    parent: openstack-ansible-functional-ubuntu-xenial
33
-    voting: false
34
-    vars:
35
-      tox_env: ssl

+ 4
- 7
zuul.d/project.yaml View File

@@ -21,17 +21,14 @@
21 21
     check:
22 22
       jobs:
23 23
         - openstack-ansible-nfs_glance
24
-        - openstack-ansible-upgrade-ubuntu-xenial
25 24
         - openstack-ansible-v2_registry_enabled
26
-        - openstack-ansible-glance-ssl-nv
27 25
         - openstack-ansible-functional-distro_install-ubuntu-xenial
28
-          # NOTE(hwoarang) Centos7 is having some troubles with repo dependencies
29
-          # so disabling until it's investigated.
30
-        - openstack-ansible-functional-distro_install-centos-7:
31
-            voting: false
26
+        - openstack-ansible-functional-distro_install-centos-7
32 27
         - openstack-ansible-functional-distro_install-opensuse-423
33 28
     gate:
34 29
       jobs:
35 30
         - openstack-ansible-nfs_glance
36
-        - openstack-ansible-upgrade-ubuntu-xenial
37 31
         - openstack-ansible-v2_registry_enabled
32
+        - openstack-ansible-functional-distro_install-ubuntu-xenial
33
+        - openstack-ansible-functional-distro_install-centos-7
34
+        - openstack-ansible-functional-distro_install-opensuse-423

Loading…
Cancel
Save