mirror of
https://github.com/simonw/datasette.git
synced 2026-06-11 19:46:58 +02:00
parent
92848c06b8
commit
648a34ce81
1 changed files with 6 additions and 2 deletions
|
|
@ -349,7 +349,11 @@ async def test_facet_display(ds_client):
|
|||
{
|
||||
"name": a.text,
|
||||
"qs": a["href"].split("?")[-1],
|
||||
"count": int(str(a.parent).split("</a>")[1].split("<")[0]),
|
||||
"count": int(
|
||||
a.parent.find(
|
||||
"span", {"class": "facet-count"}
|
||||
).text.replace(",", "")
|
||||
),
|
||||
}
|
||||
for a in div.find("ul").find_all("a")
|
||||
],
|
||||
|
|
@ -695,7 +699,7 @@ async def test_table_html_foreign_key_facets(ds_client):
|
|||
assert response.status_code == 200
|
||||
assert (
|
||||
'<li><a href="http://localhost/fixtures/foreign_key_references?_facet=foreign_key_with_blank_label&foreign_key_with_blank_label=3"'
|
||||
' data-facet-value="3">-</a> 1</li>'
|
||||
' data-facet-value="3">-</a> <span class="facet-count">1</span></li>'
|
||||
) in response.text
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue