def test_bytesOutOfRange(self):
        """
        L{networkString} raises C{UnicodeError} if passed a C{bytes} instance
        containing bytes not used by ASCII.
        """
        self.assertRaises(
            UnicodeError, networkString, u"\N{SNOWMAN}".encode('utf-8'))

        L{networkString} raises C{UnicodeError} if passed a C{bytes} instance
        containing bytes not used by ASCII.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/test/test_compat.py