def molten_client(headers=None, params=None): app = molten.App(routes=[molten.Route('/hello/{name}/{age}', hello)]) client = TestClient(app) uri = app.reverse_uri('hello', name='Jim', age=24) return client.request('GET', uri, headers=headers, params=params)
def molten_client(headers=None, params=None): app = molten.App(routes=[molten.Route("/hello/{name}/{age}", hello)]) client = TestClient(app) uri = app.reverse_uri("hello", name="Jim", age=24) return client.request("GET", uri, headers=headers, params=params)
import molten from config import PING_MESSAGE def ping(): return PING_MESSAGE.format(app='molten') app = molten.App(routes=[molten.Route('/', ping)])