Skip to content

Commit e2d4a33

Browse files
committed
Fix for Python 2.7
1 parent 5608edc commit e2d4a33

File tree

1 file changed

+18
-18
lines changed

1 file changed

+18
-18
lines changed

pytest_reportportal/config.py

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -85,12 +85,12 @@ def __init__(self, pytest_config):
8585
if rp_api_retries and rp_api_retries > 0:
8686
self.rp_api_retries = rp_api_retries
8787
warnings.warn(
88-
message='Parameter `retries` is deprecated since 5.1.9 '
89-
'and will be subject for removing in the next '
90-
'major version. Use `rp_api_retries` argument '
91-
'instead.',
92-
category=DeprecationWarning,
93-
stacklevel=2
88+
'Parameter `retries` is deprecated since 5.1.9 '
89+
'and will be subject for removing in the next '
90+
'major version. Use `rp_api_retries` argument '
91+
'instead.',
92+
DeprecationWarning,
93+
2
9494
)
9595
else:
9696
self.rp_api_retries = 0
@@ -102,21 +102,21 @@ def __init__(self, pytest_config):
102102
'RP_UUID') or self.find_option(pytest_config, 'rp_uuid')
103103
if self.rp_api_key:
104104
warnings.warn(
105-
message='Parameter `rp_uuid` is deprecated since 5.1.9 '
106-
'and will be subject for removing in the next '
107-
'major version. Use `rp_api_key` argument '
108-
'instead.',
109-
category=DeprecationWarning,
110-
stacklevel=2
105+
'Parameter `rp_uuid` is deprecated since 5.1.9 '
106+
'and will be subject for removing in the next '
107+
'major version. Use `rp_api_key` argument '
108+
'instead.',
109+
DeprecationWarning,
110+
2
111111
)
112112
else:
113113
warnings.warn(
114-
message='Argument `rp_api_key` is `None` or empty string, '
115-
'that is not supposed to happen because Report '
116-
'Portal is usually requires an authorization key. '
117-
'Please check your configuration.',
118-
category=RuntimeWarning,
119-
stacklevel=2
114+
'Argument `rp_api_key` is `None` or empty string, '
115+
'that is not supposed to happen because Report '
116+
'Portal is usually requires an authorization key. '
117+
'Please check your configuration.',
118+
RuntimeWarning,
119+
2
120120
)
121121

122122
rp_verify_ssl = self.find_option(pytest_config, 'rp_verify_ssl', True)

0 commit comments

Comments
 (0)