File tree Expand file tree Collapse file tree 3 files changed +17
-2
lines changed Expand file tree Collapse file tree 3 files changed +17
-2
lines changed Original file line number Diff line number Diff line change @@ -475,7 +475,7 @@ def get_marker_value(item, keyword):
475475 return tags
476476
477477 def _get_parameters (self , item ):
478- return item .callspec .params if hasattr (item , 'callspec' ) else {}
478+ return item .callspec .params if hasattr (item , 'callspec' ) else None
479479
480480 @staticmethod
481481 def _get_item_name (test_item ):
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ def read_file(fname):
88 return f .read ()
99
1010
11- version = '5.0.1 '
11+ version = '5.0.2 '
1212
1313
1414requirements = [
Original file line number Diff line number Diff line change 22
33from six .moves import mock
44
5+ from delayed_assert import expect , assert_expectations
56import pytest
67
78
@@ -28,3 +29,17 @@ def __iter__(self):
2829 test_item .get_closest_marker = get_closest_marker
2930 markers = rp_service ._get_item_markers (test_item )
3031 assert markers == [{'value' : 'test_marker' }, {'value' : 'ini_marker' }]
32+
33+
34+ def test_get_item_parameters (rp_service ):
35+ """Test that parameters are returned in a way supported by the client."""
36+ test_item = mock .Mock ()
37+ test_item .callspec .params = {'param' : 'param_value' }
38+
39+ expect (rp_service ._get_parameters (test_item ) == {'param' : 'param_value' })
40+
41+ delattr (test_item , 'callspec' )
42+ expect (rp_service ._get_parameters (test_item ) is None )
43+
44+ assert_expectations ()
45+
You can’t perform that action at this time.
0 commit comments