diff --git a/defaults/main.yml b/defaults/main.yml index 7e27cd8f..9c4048e8 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -87,29 +87,32 @@ tempest_plugins: "{{ _tempest_plugins.values() | sum(start=[]) | selectattr('ins # tempest_workspace where tempest can be runned tempest_workspace: "{{ ansible_facts['env']['HOME'] }}/workspace" -# The location where the test whitelist/blacklist will be placed -tempest_test_whitelist_file_path: "{{ tempest_workspace }}/etc/tempest_whitelist.txt" -tempest_test_blacklist_file_path: "{{ tempest_workspace }}/etc/tempest_blacklist.txt" +# The location where the test include/exclude lists will be placed +tempest_test_includelist_file_path: "{{ tempest_workspace }}/etc/tempest_includelist.txt" +tempest_test_excludelist_file_path: "{{ tempest_workspace }}/etc/tempest_excludelist.txt" # Tests to execute: # This sets up a list of tests to execute based on what's deployed in the environment. -# The list gets added to the whitelist which tempest executes. -tempest_test_whitelist: +# The list gets added to the includelist which tempest executes. +# Defaults to tempest_test_whitelist for backwards compatibility and migration purposes. +tempest_test_includelist: "{{ tempest_test_whitelist | default(tempest_test_default_includelist) }}" +tempest_test_default_includelist: - "smoke" - "{{ (tempest_service_available_ceilometer | bool) | ternary('tempest.api.telemetry', '') }}" - "{{ (tempest_service_available_heat | bool) | ternary('tempest.api.orchestration.stacks.test_non_empty_stack', '') }}" # Tests being skipped by os_tempest # Example: -# tempest_test_blacklist: +# tempest_test_excludelist: # - test: tempest.scenario.test.minimum_basic # reason: This test is failing # lp: 'https://bugs.launchpad.net/openstack-ansible/+bug/123456' # bz: 'https://bugzilla.redhat.com/show_bug.cgi?id=123456' # OR -# tempest_test_blacklist: +# tempest_test_excludelist: # - 'tempest.scenario.test.minimum_basic' -tempest_test_blacklist: [] +# Defaults to tempest_test_blacklist for backwards compatibility and migration purposes. +tempest_test_excludelist: "{{ tempest_test_blacklist | default([]) }}" # Toggle fatal deprecations tempest_fatal_deprecations: False diff --git a/releasenotes/notes/rename-whitelist-blacklist-5de882e5585bceb0.yaml b/releasenotes/notes/rename-whitelist-blacklist-5de882e5585bceb0.yaml new file mode 100644 index 00000000..5008d697 --- /dev/null +++ b/releasenotes/notes/rename-whitelist-blacklist-5de882e5585bceb0.yaml @@ -0,0 +1,6 @@ +--- +deprecations: + - Renamed ``tempest_test_whitelist`` to ``tempest_test_includelist`` and + ``tempest_test_blacklist`` to ``tempest_test_excludelist`` + Dependant projects should update to use the new variables + diff --git a/tasks/tempest_post_install.yml b/tasks/tempest_post_install.yml index 2ea87619..077ee7c9 100644 --- a/tasks/tempest_post_install.yml +++ b/tasks/tempest_post_install.yml @@ -153,32 +153,32 @@ when: "debug | bool" changed_when: false -- name: Generate tempest test whitelist +- name: Generate tempest test include list copy: content: | - {% for item in tempest_test_whitelist | unique | sort %} + {% for item in tempest_test_includelist | unique | sort %} {% if item %} {{ item }} {% endif %} {% endfor %} - dest: "{{ tempest_test_whitelist_file_path }}" + dest: "{{ tempest_test_includelist_file_path }}" mode: "0644" when: - - tempest_test_whitelist | length > 0 + - tempest_test_includelist | length > 0 # Tests to NOT execute: # This sets up a list of tests to skip, which can even include those included in the whitelist. -- name: Generate tempest test blacklist +- name: Generate tempest test exclude list copy: content: | - {% for item in tempest_test_blacklist %} + {% for item in tempest_test_excludelist %} {% if item.test is defined %} {{ item.test }} {% else %} {{ item }} {% endif %} {% endfor %} - dest: "{{ tempest_test_blacklist_file_path }}" + dest: "{{ tempest_test_excludelist_file_path }}" mode: "0644" when: - - tempest_test_blacklist | length > 0 + - tempest_test_excludelist | length > 0 diff --git a/tasks/tempest_run.yml b/tasks/tempest_run.yml index fb940e80..acd3b26a 100644 --- a/tasks/tempest_run.yml +++ b/tasks/tempest_run.yml @@ -30,10 +30,10 @@ {% if tempest_test_worker_file_path is defined %} --worker-file {{ tempest_test_worker_file_path }} \ {% endif %} - {% if tempest_test_blacklist | length > 0 %} - --blacklist-file {{ tempest_test_blacklist_file_path }} \ + {% if tempest_test_excludelist | length > 0 %} + --exclude-list {{ tempest_test_excludelist_file_path }} \ {% endif %} - --whitelist-file {{ tempest_test_whitelist_file_path }} > {{ tempest_log_dir }}/tempest_run.log + --include-list {{ tempest_test_includelist_file_path }} > {{ tempest_log_dir }}/tempest_run.log args: chdir: "{{ tempest_workspace }}" executable: /bin/bash @@ -108,9 +108,9 @@ . {{ tempest_venv_bin }}/activate fi tempest run \ - --whitelist-file {{ tempest_test_whitelist_file_path }} \ - {% if tempest_test_blacklist | length > 0 %} - --blacklist-file {{ tempest_test_blacklist_file_path }} \ + --include-list {{ tempest_test_includelist_file_path }} \ + {% if tempest_test_excludelist | length > 0 %} + --exclude-list {{ tempest_test_excludelist_file_path }} \ {% endif %} --list-tests &> {{ tempest_log_dir }}/test_list.txt args: diff --git a/zuul.d/jobs.yaml b/zuul.d/jobs.yaml index b29e1aae..83bca279 100644 --- a/zuul.d/jobs.yaml +++ b/zuul.d/jobs.yaml @@ -33,7 +33,7 @@ use_os_tempest: true tempest_tempest_conf_overrides: auth.use_dynamic_credentials: true - tempest_test_whitelist: + tempest_test_includelist: - 'tempest.api.identity.v3' - 'tempest.scenario.test_server_basic_ops' - 'tempest.api.volume.admin.test_multi_backend'