def test_interfaces(self): result = SearchResult( rids=[rid for rid, uid in _DOCMAP.items() if uid in ITEMS], idmapper=DMAP, resolver=RESOLVE_ALL, ) assert IItemCollection.providedBy(result) assert ICollectionSetOperations.providedBy(result) assert IUIDItemCollection.providedBy(result) assert ISearchResult.providedBy(result)
def test_interfaces(self): collection = BaseCollection(ITEMS, NAMES) assert IItemCollection.providedBy(collection) assert ICollectionSetOperations.providedBy(collection) assert IUIDItemCollection.providedBy(collection) assert not INamedItemCollection.providedBy(collection)