def test_reset_cache(self):
        menu = self.create_menu_item(
            label='Our Blog',
            slug='our-blog',
            order=4,
        )
        menu.to_tree()
        valid = cache.get('menu-tree-%s' % menu.slug)
        self.assertTrue(valid, 'Menu should be cached')
        cache.set('menu-tree-%s' % menu.slug, 'INVALID!!!')
        response = self.client.get(self.cache_url, follow=True)
        self.assertRedirects(response, self.changelist_url)
        self.assertEqual(len(response.context['messages']), 1)
        # Cache should be recycled
        current = cache.get('menu-tree-%s' % menu.slug)
        self.assertNotEqual(current, 'INVALID!!!')
Redirect to badge
dataset/ETHPy150Open caktus/django-treenav/treenav/tests/test_views.py/ClearCacheViewTestCase.test_reset_cache--crossover with--dataset/ETHPy150Open nvbn/coviolations_web/projects/views.py/ProjectBadge.get_redirect_url