@classmethod
    def filter_by_list(cls, iterable, field_name, list_of_values,
                       order_by=()):
        field_getter = operator.attrgetter(field_name)
        use_iterable = iterable or cls.all()
        if cls._is_query(use_iterable):
            result = use_iterable.filter(
                field_getter(cls.single.model).in_(list_of_values)
            )
            result = cls.order_by(result, order_by)
            return result
        elif cls._is_iterable(use_iterable):
            return ifilter(
                lambda i: field_getter(i) in list_of_values,
                use_iterable
            )
        else:
            raise TypeError("First argument should be iterable")
Testing an indexing given without ID
dataset/ETHPy150Open openstack/fuel-web/nailgun/nailgun/objects/base.py/NailgunCollection.filter_by_list--crossover with--dataset/ETHPy150Open aparo/pyes/tests/test_indexing.py/IndexingTestCase.testIndexingWithoutID