|
1 | | -# Copyright 2020 Axis Communications AB. |
| 1 | +# Copyright 2020-2021 Axis Communications AB. |
2 | 2 | # |
3 | 3 | # For a full list of individual contributors, please see the commit history. |
4 | 4 | # |
|
18 | 18 | ARTIFACTS, |
19 | 19 | ACTIVITY_TRIGGERED, |
20 | 20 | ACTIVITY_CANCELED, |
21 | | - CONFIDENCE_LEVEL, |
22 | 21 | TEST_SUITE_STARTED, |
23 | 22 | TEST_SUITE_FINISHED, |
24 | 23 | TEST_SUITE, |
@@ -157,34 +156,6 @@ def request_test_suite_finished(etos, test_suite_ids): |
157 | 156 | return None # StopIteration |
158 | 157 |
|
159 | 158 |
|
160 | | -def request_confidence_level(etos, test_suite_ids): |
161 | | - """Request confidence levels from graphql. |
162 | | -
|
163 | | - :param etos: Etos Library instance for communicating with ETOS. |
164 | | - :type etos: :obj:`etos_lib.etos.ETOS` |
165 | | - :param test_suite_ids: list of test suite started IDs of which confidences to search for. |
166 | | - :type test_suite_ids: list |
167 | | - :return: Iterator of confidence level modified graphql responses. |
168 | | - :rtype: iterator |
169 | | - """ |
170 | | - or_query = "{'$or': [" |
171 | | - or_query += ", ".join( |
172 | | - [ |
173 | | - "{'links.type': 'CAUSE', 'links.target': '%s'}" % test_suite_id |
174 | | - for test_suite_id in test_suite_ids |
175 | | - ] |
176 | | - ) |
177 | | - or_query += "]}" |
178 | | - for response in request(etos, CONFIDENCE_LEVEL % or_query): |
179 | | - if response: |
180 | | - for _, confidence_level in etos.graphql.search_for_nodes( |
181 | | - response, "confidenceLevelModified" |
182 | | - ): |
183 | | - yield confidence_level |
184 | | - return None # StopIteration |
185 | | - return None # StopIteration |
186 | | - |
187 | | - |
188 | 159 | def request_announcements(etos, ids): |
189 | 160 | """Request announcements from graphql. |
190 | 161 |
|
|
0 commit comments