mock.call.unindex

Here are the examples of the python api mock.call.unindex taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.

1 Examples 7

Example 1

Project: mozillians Source File: test_tasks.py
    @patch('mozillians.users.tasks.get_es')
    def test_unindex_objects(self, get_es_mock):
        mapping_type = MagicMock()
        unindex_objects(mapping_type, [1, 2, 3], 'foo')
        ok_(mapping_type.unindex.called)
        mapping_type.assert_has_calls([
            call.unindex(1, es=get_es_mock(), public_index='foo'),
            call.unindex(2, es=get_es_mock(), public_index='foo'),
            call.unindex(3, es=get_es_mock(), public_index='foo')])