Oleksii Butenko | e82441d | 2018-06-12 16:01:33 +0300 | [diff] [blame] | 1 | # Copyright 2018 Mirantis, Inc. |
| 2 | # |
| 3 | # Licensed under the Apache License, Version 2.0 (the "License"); you may |
| 4 | # not use this file except in compliance with the License. You may obtain |
| 5 | # a copy of the License at |
| 6 | # |
| 7 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | # |
| 9 | # Unless required by applicable law or agreed to in writing, software |
| 10 | # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT |
| 11 | # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the |
| 12 | # License for the specific language governing permissions and limitations |
| 13 | # under the License. |
| 14 | |
| 15 | import pytest |
| 16 | from tcp_tests import settings |
| 17 | from tcp_tests.managers.runtestmanager import RuntestManager |
| 18 | |
| 19 | |
| 20 | @pytest.fixture(scope='function') |
Dennis Dmitriev | b6bcc5c | 2018-09-26 11:07:53 +0000 | [diff] [blame] | 21 | def tempest_actions(config, underlay_actions, salt_actions): |
Oleksii Butenko | e82441d | 2018-06-12 16:01:33 +0300 | [diff] [blame] | 22 | """ |
| 23 | Run tempest tests |
| 24 | """ |
| 25 | tempest_threads = settings.TEMPEST_THREADS |
Oleksii Butenko | e82441d | 2018-06-12 16:01:33 +0300 | [diff] [blame] | 26 | tempest_pattern = settings.TEMPEST_PATTERN |
Oleksii Butenko | 25a8f37 | 2019-03-22 17:25:47 +0200 | [diff] [blame^] | 27 | tempest_extra_args = settings.TEMPEST_EXTRA_ARGS |
Oleksii Butenko | e82441d | 2018-06-12 16:01:33 +0300 | [diff] [blame] | 28 | cluster_name = settings.LAB_CONFIG_NAME |
Oleksii Butenko | 5cd0a16 | 2018-06-14 18:18:10 +0300 | [diff] [blame] | 29 | domain_name = settings.DOMAIN_NAME |
Oleksii Butenko | e82441d | 2018-06-12 16:01:33 +0300 | [diff] [blame] | 30 | runtest = RuntestManager( |
Dennis Dmitriev | b6bcc5c | 2018-09-26 11:07:53 +0000 | [diff] [blame] | 31 | config, |
Dennis Dmitriev | ee5ef23 | 2018-08-31 13:53:18 +0300 | [diff] [blame] | 32 | underlay_actions, salt_actions, |
Oleksii Butenko | e82441d | 2018-06-12 16:01:33 +0300 | [diff] [blame] | 33 | cluster_name=cluster_name, |
| 34 | domain_name=domain_name, |
Oleksii Butenko | 25a8f37 | 2019-03-22 17:25:47 +0200 | [diff] [blame^] | 35 | tempest_extra_args=tempest_extra_args, |
Oleksii Butenko | e82441d | 2018-06-12 16:01:33 +0300 | [diff] [blame] | 36 | tempest_threads=tempest_threads, |
obutenko | c431435 | 2018-12-26 16:14:24 +0200 | [diff] [blame] | 37 | tempest_pattern=tempest_pattern) |
Oleksii Butenko | e82441d | 2018-06-12 16:01:33 +0300 | [diff] [blame] | 38 | return runtest |