Skip to content

Commit 9664dde

Browse files
committed
Avoid test failures by adding a 'reporter' attributed to 'state_machine'
also pass 'name=' for what appear to be names for the Mock objects --- Signed-off-by: Michael Ferguson <[email protected]>
1 parent b6bb0e4 commit 9664dde

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

test/test_chapeldomain.py

+8-8
Original file line numberDiff line numberDiff line change
@@ -169,14 +169,14 @@ def new_obj(self, objtype, **kwargs):
169169
"""Return new mocked out ChapelObject"""
170170
default_args = {
171171
'name': 'my-chpl',
172-
'arguments': mock.Mock('arguments'),
173-
'options': mock.Mock('options'),
174-
'content': mock.Mock('content'),
175-
'lineno': mock.Mock('lineno'),
176-
'content_offset': mock.Mock('content_offset'),
177-
'block_text': mock.Mock('block_text'),
178-
'state': mock.Mock('state'),
179-
'state_machine': mock.Mock('state_machine'),
172+
'arguments': mock.Mock(name='arguments'),
173+
'options': mock.Mock(name='options'),
174+
'content': mock.Mock(name='content'),
175+
'lineno': mock.Mock(name='lineno'),
176+
'content_offset': mock.Mock(name='content_offset'),
177+
'block_text': mock.Mock(name='block_text'),
178+
'state': mock.Mock(name='state'),
179+
'state_machine': mock.Mock(name='state_machine', spec=["reporter",]),
180180
}
181181
default_args.update(kwargs)
182182
o = self.object_cls(**default_args)

0 commit comments

Comments
 (0)