def _list_base_images(self, base_dir):

        digest_size = hashlib.sha1().digestsize * 2
        for ent in os.listdir(base_dir):
            if len(ent) == digest_size:
                self._store_image(base_dir, ent, original=True)

            elif (len(ent) > digest_size + 2 and
                  ent[digest_size] == '_' and
                  not is_valid_info_file(os.path.join(base_dir, ent))):
                self._store_image(base_dir, ent, original=False)
            else:
                self._store_swap_image(ent)

        return {'unexplained_images': self.unexplained_images,
                'originals': self.originals}
Test of a simple raw query against a model containing a m2m field
dataset/ETHPy150Open BU-NU-CLOUD-SP16/Trusted-Platform-Module-nova/nova/virt/libvirt/imagecache.py/ImageCacheManager._list_base_images--crossover with--dataset/ETHPy150Open AppScale/appscale/AppServer/lib/django-1.4/tests/modeltests/raw_query/tests.py/RawQueryTests.testManyToMany