def test_process_item_single(self):
    provider = MockProviderSingle(self._default_collection)
    provider.parser = MockParserSingle()
    id = self._id('single')
    result = provider.process_item(id)
    assert (etree.tostring(provider.called_with['tree']) == etree.tostring(provider._get_tree(isbn=self.SINGLE_ISBN)))
    assert isinstance(provider.called_with['metadata'], Metadata)
    assert (provider.called_with['metadata'].primary_identifier == id)
    assert (result == id)
def test_process_item_single(self):
    provider = MockProviderSingle(self._default_collection)
    provider.parser = MockParserSingle()
    id = self._id('single')
    result = provider.process_item(id)
    assert (etree.tostring(provider.called_with['tree']) == etree.tostring(provider._get_tree(isbn=self.SINGLE_ISBN)))
    assert isinstance(provider.called_with['metadata'], Metadata)
    assert (provider.called_with['metadata'].primary_identifier == id)
    assert (result == id)