Async support for prepare_jinja2_environment, closes #1809

This commit is contained in:
Simon Willison 2022-09-16 20:38:15 -07:00
commit ddc999ad12
10 changed files with 76 additions and 9 deletions

View file

@ -59,6 +59,7 @@ def test_routes(routes, path, expected_class, expected_matches):
@pytest_asyncio.fixture
async def ds_with_route():
ds = Datasette()
await ds.invoke_startup()
ds.remove_database("_memory")
db = Database(ds, is_memory=True, memory_name="route-name-db")
ds.add_database(db, name="original-name", route="custom-route-name")