Skip to content

Commit 3ed89c6

Browse files
committed
Remove unused functions
1 parent d061864 commit 3ed89c6

File tree

1 file changed

+14
-47
lines changed

1 file changed

+14
-47
lines changed

reportportal_client/items/rp_base_item.py

Lines changed: 14 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,19 @@
1-
"""
2-
This module contains functional for Base RP items management.
3-
4-
Copyright (c) 2018 http://reportportal.io .
5-
6-
Licensed under the Apache License, Version 2.0 (the "License");
7-
you may not use this file except in compliance with the License.
8-
You may obtain a copy of the License at
9-
10-
http://www.apache.org/licenses/LICENSE-2.0
11-
12-
Unless required by applicable law or agreed to in writing, software
13-
distributed under the License is distributed on an "AS IS" BASIS,
14-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15-
See the License for the specific language governing permissions and
16-
limitations under the License.
17-
"""
1+
"""This module contains functional for Base RP items management."""
2+
3+
# Copyright (c) 2023 EPAM Systems
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+
# https://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
1815

1916
from reportportal_client.core.rp_requests import HttpRequest
20-
from reportportal_client.core.rp_responses import RPResponse
21-
from reportportal_client.static.defines import NOT_FOUND
2217

2318

2419
class BaseRPItem(object):
@@ -52,34 +47,6 @@ def http_request(self):
5247
"""
5348
return self.http_requests[-1] if self.http_requests else None
5449

55-
@property
56-
def response(self):
57-
"""Get last http response.
58-
59-
:return: Response data object
60-
"""
61-
return self.responses[-1] if self.responses else None
62-
63-
@response.setter
64-
def response(self, data):
65-
"""Set the response object for the test item.
66-
67-
:param data: Response data object
68-
"""
69-
response = RPResponse(data)
70-
self.responses.append(response)
71-
self.uuid = response.id if (response.id is
72-
not NOT_FOUND) else self.uuid
73-
74-
@property
75-
def unhandled_requests(self):
76-
"""Get list of requests that were not handled.
77-
78-
:return: list of HttpRequest objects
79-
"""
80-
return [request for request in self.http_requests
81-
if not request.response]
82-
8350
def add_request(self, endpoint, method, request_class, *args, **kwargs):
8451
"""Add new request object.
8552

0 commit comments

Comments
 (0)