def fetch(self, *args, **kwargs):
        result = self.get(*args, **kwargs)
        if isinstance(result, collections.Iterable):
            return self.filter(pk__in=[self.get_or_create_from_instance(instance).pk for instance in result])
        else:
            return self.get_or_create_from_instance(result)
Create the application for the test case.
dataset/ETHPy150Open ramusus/django-twitter-api/twitter_api/models.py/TwitterManager.fetch--crossover with--dataset/ETHPy150Open ipython/ipython-py3k/IPython/frontend/qt/console/tests/test_kill_ring.py/TestKillRing.setUpClass