'L{HTTPParser} calls its C{headerReceived} method when it receives a
header.'

def test_headerCallback(self):

    (header, protocol) = self._headerTestSetup()
    protocol.dataReceived(('X-Foo:bar' + self.sep))
    protocol.dataReceived(self.sep)
    self.assertEqual(header, {'X-Foo': 'bar'})
    self.assertEqual(protocol.state, BODY)
