def test_serializeCoroutine(self):
        """
        Test that a coroutine returning a value is substituted with the that
        value when flattened.
        """
        from textwrap import dedent
        namespace = {}
        exec(dedent(
            """
            async def coro(x):
                return x
            """
        ), namespace)
        coro = namespace["coro"]

        return self.assertFlattensTo(coro('four'), b'four')

        Test that a coroutine returning a value is substituted with the that
        value when flattened.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/web/test/test_flatten.py