mirror of
https://github.com/simonw/datasette.git
synced 2025-12-10 16:51:24 +01:00
--get now calls startup() plugin hooks, closes #934
This commit is contained in:
parent
7702ea6021
commit
45414f8412
4 changed files with 59 additions and 21 deletions
|
|
@ -50,20 +50,6 @@ def test_serve_with_inspect_file_prepopulates_table_counts_cache():
|
|||
assert {"hithere": 44} == db.cached_table_counts
|
||||
|
||||
|
||||
def test_serve_with_get():
|
||||
runner = CliRunner()
|
||||
result = runner.invoke(
|
||||
cli,
|
||||
["serve", "--memory", "--get", "/:memory:.json?sql=select+sqlite_version()"],
|
||||
)
|
||||
assert 0 == result.exit_code, result.output
|
||||
assert {
|
||||
"database": ":memory:",
|
||||
"truncated": False,
|
||||
"columns": ["sqlite_version()"],
|
||||
}.items() <= json.loads(result.output).items()
|
||||
|
||||
|
||||
def test_spatialite_error_if_attempt_to_open_spatialite():
|
||||
runner = CliRunner()
|
||||
result = runner.invoke(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue