'Context variables can be retrieved from a list of contexts'

def test_inherited_context(self):

    response = self.client.get('/test_client_regress/request_data_extended/', data={'foo': 'whiz'})
    self.assertEqual(response.context.__class__, ContextList)
    self.assertEqual(len(response.context), 2)
    self.assertTrue(('get-foo' in response.context))
    self.assertEqual(response.context['get-foo'], 'whiz')
    self.assertEqual(response.context['request-foo'], 'whiz')
    self.assertEqual(response.context['data'], 'bacon')
    try:
        response.context['does-not-exist']
        self.fail('Should    not    be    able    to    retrieve    non-existent    key')
    except KeyError as e:
        self.assertEquals(e.args[0], 'does-not-exist')
