MCPcopy Create free account
hub / github.com/vercel/vercel / test_base64_body

Method test_base64_body

python/vercel-runtime/tests/test_runtime.py:1809–1822  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1807 self.assertEqual(body, "GET /hello")
1808
1809 async def test_base64_body(self) -> None:
1810 ep_abs, ep_rel, mod = _make_entrypoint("asgi_app.py", self.tmp_path)
1811 result = await _invoke_lambda(
1812 entrypoint_abs=ep_abs,
1813 entrypoint_rel=ep_rel,
1814 module_name=mod,
1815 event=_lambda_event(
1816 "POST",
1817 "/data",
1818 body=base64.b64encode(b"bin").decode(),
1819 encoding="base64",
1820 ),
1821 )
1822 self.assertEqual(result["statusCode"], 200)
1823
1824 async def test_repeated_headers(self) -> None:
1825 ep_abs, ep_rel, mod = _make_entrypoint(

Callers

nothing calls this directly

Calls 4

_make_entrypointFunction · 0.85
_invoke_lambdaFunction · 0.85
_lambda_eventFunction · 0.85
decodeMethod · 0.80

Tested by

no test coverage detected