mirror of
https://github.com/simonw/datasette.git
synced 2025-12-10 16:51:24 +01:00
Correctly escape output of ?_trace, refs #1360
This commit is contained in:
parent
ff29dd55fa
commit
8f311d6c1d
2 changed files with 8 additions and 1 deletions
|
|
@ -1699,3 +1699,9 @@ def test_unavailable_table_does_not_break_sort_relationships():
|
|||
) as client:
|
||||
response = client.get("/?_sort=relationships")
|
||||
assert response.status == 200
|
||||
|
||||
|
||||
def test_trace_correctly_escaped(app_client):
|
||||
response = app_client.get("/fixtures?sql=select+'<h1>Hello'&_trace=1")
|
||||
assert "select '<h1>Hello" not in response.text
|
||||
assert "select '<h1>Hello" in response.text
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue