def test_app_list(self):
        xr = self.client.get('/')
        self.assertEqual(xr.status_code, 302)
        
        self.client.login(username='user', password='')
        xr = self.client.get('/')
        self.assertEqual(xr.status_code, 302)
        
        AppPermission.objects.assign('rubberstamp.manage.rubberstamp.apppermission', self.user)
        r = self.client.get('/')
        self.assertEqual(r.status_code, 200)
        
        ap_ct = ContentType.objects.get(app_label='rubberstamp', model='apppermission')
        tm_ct = ContentType.objects.get(app_label='testapp', model='testmodel')
        otm_ct = ContentType.objects.get(app_label='testapp', model='othertestmodel')
        apps = [
            {
                'label': u'rubberstamp',
                'perms': [
                    {
                        'codename': u'manage',
                        'types': [ap_ct]
                    },
                ],
            },
            {
                'label': u'testapp',
                'perms': [
                    {
                        'codename': u'have',
                        'types': [tm_ct]
                    },
                    {
                        'codename': u'use',
                        'types': [otm_ct, tm_ct]
                    },
                ],
            },
        ]
        self.assertEqual(repr(r.context['apps']), repr(apps))
Gets or creates the container.
dataset/ETHPy150Open jlecker/django-rubberstamp/rubberstamp/tests/views.py/ViewTest.test_app_list--crossover with--dataset/ETHPy150Open django-cumulus/django-cumulus/cumulus/authentication.py/Auth._get_container