def test_dontCallInstanceMethodsThatArentReady(self):
        """
        L{crefutil._InstanceMethod} raises L{AssertionError} to indicate it
        should not be called.  This should not be possible with any of its API
        clients, but is provided for helping to debug.
        """
        self.assertRaises(AssertionError,
                          crefutil._InstanceMethod(
                              "no_name", crefutil.NotKnown(), type))

        L{crefutil._InstanceMethod} raises L{AssertionError} to indicate it
        should not be called.  This should not be possible with any of its API
        clients, but is provided for helping to debug.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/test/test_persisted.py