'Tests a simple request'

def test_basic(self):

    Channel(u'test').send({u'reply_channel': u'test', u'http_version': u'1.1', u'method': u'GET', u'path': '/test/'})
    response = HttpResponse('Hi    there!', content_type=u'text/plain')
    handler = FakeAsgiHandler(response)
    reply_messages = list(handler(self.get_next_message(u'test', require=True)))
    self.assertEqual(len(reply_messages), 1)
    reply_message = reply_messages[0]
    self.assertEqual(reply_message[u'content'], 'Hi    there!')
    self.assertEqual(reply_message[u'status'], 200)
    self.assertEqual(reply_message.get(u'more_content', False), False)
    self.assertEqual(reply_message[u'headers'], [('Content-Type', 'text/plain')])
