def test_responseId(self):
        """
        L{dns._responseFromMessage} copies the C{id} attribute of the original
        message.
        """
        self.assertEqual(
            1234,
            dns._responseFromMessage(responseConstructor=dns.Message,
                                     message=dns.Message(id=1234)).id
        )

        L{dns._responseFromMessage} copies the C{id} attribute of the original
        message.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/names/test/test_dns.py