heat/roles/run-heat-tests/tasks/main.yaml
ramishra 22c48f57bb Use constraints when creating tempest venv
When running tempest we run in-tree tests as well. Lots of these
tests including tempest tests may not work with new client
libraries. Let's use the relevant branch upper constraints when
running functional tests.

Change-Id: I6a8cffdc86c895eebe4269c5cd37841325566c54
2022-06-07 12:59:35 +05:30

29 lines
1.1 KiB
YAML

- name: Set OS_TEST_TIMEOUT if requested
set_fact:
tempest_tox_environment: "{{ tempest_tox_environment | combine({'OS_TEST_TIMEOUT': tempest_test_timeout}) }}"
when: tempest_test_timeout != ''
- name: Set TOX_CONSTRAINTS_FILE
set_fact:
tempest_tox_environment: "{{ tempest_tox_environment | combine({'UPPER_CONSTRAINTS_FILE': constraints_file}) | combine({'TOX_CONSTRAINTS_FILE': constraints_file}) }}"
- name: Allow git to read plugin directories
become: true
command: git config --system --add safe.directory {{heat_tempest_plugin}}
- name: Install plugins
command: tox -evenv-tempest -- pip install -c{{constraints_file}} {{heat_tempest_plugin}}
become: true
args:
chdir: "{{devstack_base_dir}}/tempest"
environment: "{{ tempest_tox_environment }}"
- name: Run heat tests
command: tox -evenv-tempest -- stestr --test-path={{devstack_base_dir}}/heat/heat_integrationtests \
--top-dir={{devstack_base_dir}}/heat \
--group_regex='heat_tempest_plugin\.tests\.api\.test_heat_api[._]([^_]+)' run
args:
chdir: "{{devstack_base_dir}}/tempest"
become: true
environment: "{{ tempest_tox_environment }}"