File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change 1010from _pytest .nodes import File , Item
1111from _pytest .python import Class , Function , Instance , Module
1212from _pytest .unittest import TestCaseFunction , UnitTestCase
13+ from _pytest .warning_types import PytestWarning
1314from reportportal_client import ReportPortalServiceAsync
1415from six import with_metaclass
1516from six .moves import queue
@@ -454,9 +455,10 @@ def _get_item_name(test_item):
454455 if len (name ) > 256 :
455456 name = name [:256 ]
456457 test_item .warn (
457- 'C1' ,
458- 'Test node ID was truncated to "{}" because of name size '
459- 'constrains on reportportal' .format (name )
458+ PytestWarning (
459+ 'Test node ID was truncated to "{}" because of name size '
460+ 'constrains on reportportal' .format (name )
461+ )
460462 )
461463 return name
462464
You can’t perform that action at this time.
0 commit comments