forked from openlp/openlp
Merge branch 'test-improvements' into 'master'
Test improvements See merge request openlp/openlp!87
This commit is contained in:
commit
f5ffc6d57e
@ -232,7 +232,8 @@ class TestSongMaintenanceForm(TestCase, TestMixin):
|
||||
expected_widget_item_calls = [call('John Wesley'), call('John Newton')]
|
||||
mocked_authors_list_widget.clear.assert_called_once_with()
|
||||
self.mocked_manager.get_all_objects.assert_called_once_with(MockedAuthor)
|
||||
assert MockedQListWidgetItem.call_args_list == expected_widget_item_calls, MockedQListWidgetItem.call_args_list
|
||||
# former third argument for below not needed anymore: MockedQListWidgetItem.call_args_list
|
||||
self.assertCountEqual(MockedQListWidgetItem.call_args_list, expected_widget_item_calls)
|
||||
mocked_author_item1.setData.assert_called_once_with(QtCore.Qt.UserRole, 2)
|
||||
mocked_author_item2.setData.assert_called_once_with(QtCore.Qt.UserRole, 1)
|
||||
mocked_authors_list_widget.addItem.assert_has_calls([
|
||||
|
@ -78,7 +78,7 @@ def test_zeroconf_worker_stop():
|
||||
worker.stop()
|
||||
|
||||
# THEN: _can_run should be False
|
||||
assert worker._can_run is False
|
||||
assert worker.can_run() is False
|
||||
|
||||
|
||||
@patch('openlp.core.api.zeroconf.get_network_interfaces')
|
||||
|
Loading…
Reference in New Issue
Block a user