diff --git a/application/core/templates.py b/application/core/templates.py
index c1a186f7..eb5da6e2 100644
--- a/application/core/templates.py
+++ b/application/core/templates.py
@@ -56,7 +56,7 @@ def random_int(n=1):
templates.env.globals["enable_x_ref"] = True
templates.env.globals["includeAutocomplete"] = True
templates.env.globals["random_int"] = random_int
-templates.env.globals["templateVar"] = {"email": "digitalland@levellingup.gov.uk"}
+templates.env.globals["templateVar"] = {"email": "digitalland@communities.gov.uk"}
templates.env.globals["serviceStatus"] = False
templates.env.globals["gaMeasurementId"] = settings.GA_MEASUREMENT_ID
templates.env.globals["get_os_oauth2_token"] = get_os_oauth2_token
diff --git a/application/factory.py b/application/factory.py
index bf310ea6..83178fde 100644
--- a/application/factory.py
+++ b/application/factory.py
@@ -72,7 +72,7 @@ def create_app():
version="0.1.0",
contact={
"name": "planning.data.gov.uk team",
- "email": "digitalland@levellingup.gov.uk",
+ "email": "digitalland@communities.gov.uk",
"url": "https://www.planning.data.gov.uk",
},
license_info={
diff --git a/application/routers/dataset.py b/application/routers/dataset.py
index 545267cc..eb02f884 100644
--- a/application/routers/dataset.py
+++ b/application/routers/dataset.py
@@ -25,6 +25,22 @@
logger = logging.getLogger(__name__)
+def get_origin_label(dataset):
+ labels = {
+ "alpha": (
+ "Data created by MHCLG. We will replace this with data from authoritative sources "
+ "when it is available."
+ ),
+ "beta": (
+ "Contains some data created by MHCLG. We are working to replace it with data "
+ "from authoritative sources"
+ ),
+ "live": "All data from authoritative sources",
+ "live+": "All data from authoritative sources with additional supporting data.",
+ }
+ return labels.get(dataset.phase, "Unknown")
+
+
def get_datasets_by_typology(datasets):
typologies = {}
for ds in (d for d in datasets if d.typology):
@@ -109,11 +125,12 @@ def get_dataset(
"current": publisher_coverage.publisher_count,
},
"latest_resource": latest_resource,
- "last_collection_attempt": latest_resource.last_collection_attempt
- if latest_resource
- else None,
+ "last_collection_attempt": (
+ latest_resource.last_collection_attempt if latest_resource else None
+ ),
"categories": categories,
"data_file_url": data_file_url,
+ "dataset_origin_label": get_origin_label(_dataset),
},
)
diff --git a/application/routers/entity.py b/application/routers/entity.py
index c82b64c8..81f66453 100644
--- a/application/routers/entity.py
+++ b/application/routers/entity.py
@@ -259,6 +259,15 @@ def search_entities(
extension: Optional[SuffixEntity] = None,
session: Session = Depends(get_session),
):
+ # Determine if the URL path includes an extension
+ if "." in request.url.path: # check if extension if in path parameter
+ extension = extension
+ else:
+ if request.query_params.get(
+ "extension"
+ ): # check if extension if in query parameter
+ extension = None
+
# get query_filters as a dict
query_params = asdict(query_filters)
# TODO minimse queries by using normal queries below rather than returning the names
@@ -271,7 +280,6 @@ def search_entities(
validate_typologies(query_params.get("typology", None), typology_names)
# Run entity query
data = get_entity_search(session, query_params)
-
# the query does some normalisation to remove empty
# params and they get returned from search
params = data["params"]
diff --git a/application/templates/components/phase-banner/macro.jinja b/application/templates/components/phase-banner/macro.jinja
index 11318161..599ca80c 100644
--- a/application/templates/components/phase-banner/macro.jinja
+++ b/application/templates/components/phase-banner/macro.jinja
@@ -4,7 +4,7 @@
"tag": {
"text": params.phase
},
- "html": params.html | default('This is a prototype. Your feedback will help us to improve it.'),
+ "html": params.html | default('This is a prototype. Your feedback will help us to improve it.'),
"classes": params.classes,
"attributes": params.attributes
}) }}
diff --git a/application/templates/dataset.html b/application/templates/dataset.html
index f453cc8e..80a70f4b 100644
--- a/application/templates/dataset.html
+++ b/application/templates/dataset.html
@@ -70,6 +70,14 @@
{{ dataset["name"] }}
{
'html': latest_resource.last_updated if latest_resource.last_updated else 'N/A'
},
+ ],
+ [
+ {
+ 'html': 'Origin'
+ },
+ {
+ 'html': dataset_origin_label
+ }
]
]
%}
diff --git a/application/templates/fact.html b/application/templates/fact.html
index 1e85c5f6..63314caf 100644
--- a/application/templates/fact.html
+++ b/application/templates/fact.html
@@ -56,7 +56,7 @@ Fact
{%- elif field == 'value' and fact['field'] in ["geometry","point"] %}
{{ fact[field] }}
{%- elif field == 'entity-name' %}
- {{ fact[field] }}
+ {{ fact[field] }}
{%- elif field == 'reference-entity' %}
{{ fact[field] }}
{%- else %}
diff --git a/application/templates/homepage.html b/application/templates/homepage.html
index d0cf6065..f86b3a50 100644
--- a/application/templates/homepage.html
+++ b/application/templates/homepage.html
@@ -110,7 +110,7 @@ {% if params.title %}{{ params.title }}{% else %}Ple
'src': '/images/providers-dashboard',
},
'link': {
- 'href': 'https://www.planning.data.gov.uk/guidance',
+ 'href': 'https://check.planning.data.gov.uk/manage',
'text': 'Check and provide planning data'
},
})
diff --git a/application/templates/layouts/layout--about.html b/application/templates/layouts/layout--about.html
index 78c893c8..163bdd00 100644
--- a/application/templates/layouts/layout--about.html
+++ b/application/templates/layouts/layout--about.html
@@ -51,6 +51,12 @@ {{ pageData.pageTitle }}
+
+131 data sources out of 584 provided by 31 local planning authorities. 4 up from last month (+0.7%).
+
+1 new local planning authority providing data. 1 up from last month (+1%).
+
+You can [help identify and design data](https://www.planning.data.gov.uk/) that would be useful on the platform.
+
+## Quality
+
+We check data sources for issues and help data owners improve the quality. This increases the quality and trustworthiness of the data at national scale. For example, we check for invalid dates, geometries that fall outside of administrative boundaries, and identify duplicate entities that need reconciling.
+
+
+
+62 data sources on the platform with no issues (47%). 8 fixed last month (+15%).
+
+24 data sources on the platform conform to the specifications (18%). 4 improved last month (+4%).
+
+
+
+## Coverage
+
+We aim to provide datasets covering the entirety of England. We’re currently working with 73 out of 311 local planning authorities to start providing 8 datasets nationally.
+
+
+
+
+
+Datasets compiled from LPA sources:
+
+* 4% coverage of Article 4 direction. No change from last month.
+* 8% coverage of Article 4 direction area. No change from last month.
+* 10% coverage of Conservation area. No change from last month.
+* 1% coverage of Conservation area document. No change from last month.
+* 6% coverage of Listed building outline. No change from last month.
+* 3% coverage of Tree preservation order. No change from last month.
+* 5% coverage of Tree preservation zone. No change from last month.
+* 4% coverage of Tree. No change from last month.
+
+
diff --git a/application/templates/pages/accessibility-statement.md b/application/templates/pages/accessibility-statement.md
index 3fb78245..bf3eb0be 100644
--- a/application/templates/pages/accessibility-statement.md
+++ b/application/templates/pages/accessibility-statement.md
@@ -70,7 +70,7 @@ We will outsource an accessibility audit on this website in the near future and
## How to request content in an accessible format
-If you need information in a different format, for example large print or accessible PDF, email and tell us:
+If you need information in a different format, for example large print or accessible PDF, email and tell us:
- the web address (URL) of the content
- your name and email address
@@ -80,7 +80,7 @@ We'll consider your request and get back to you in 21 days.
## Reporting accessibility problems with this website
-If you find any problems that are not listed on this page, or you think we're not meeting the accessibility requirements, please email so that we can fix the issue.
+If you find any problems that are not listed on this page, or you think we're not meeting the accessibility requirements, please email so that we can fix the issue.
## Enforcement procedure
diff --git a/application/templates/pages/guidance/publish-data-on-your-website.md b/application/templates/pages/guidance/publish-data-on-your-website.md
index 7093c816..472ec226 100644
--- a/application/templates/pages/guidance/publish-data-on-your-website.md
+++ b/application/templates/pages/guidance/publish-data-on-your-website.md
@@ -34,7 +34,7 @@ The data is provided under the [Open Government Licence](https://www.nationalarc
Tell us about the webpage
-------------
-Send an email to [digitalland@levellingup.gov.uk](mailto:digitalland@levellingup.gov.uk).
+Send an email to [digitalland@communities.gov.uk](mailto:digitalland@communities.gov.uk).
The email must include:
diff --git a/application/templates/pages/guidance/specifications/article-4-direction.md b/application/templates/pages/guidance/specifications/article-4-direction.md
index 0ede8fd5..10f07000 100644
--- a/application/templates/pages/guidance/specifications/article-4-direction.md
+++ b/application/templates/pages/guidance/specifications/article-4-direction.md
@@ -22,6 +22,19 @@ You can provide data in one of these formats:
These may be uploaded to a single URL, or served via an OGC WFS or ArcGIS API.
+Field names
+-----------
+
+You can provide fields names using hyphens, underscores or spaces.
+
+For example:
+
+- `start-date`
+- `start_date`
+- `start date`
+
+These are all valid, and any uppercase characters will be converted to lowercase.
+
---
## Article 4 direction dataset
@@ -64,7 +77,7 @@ Example: `http://www.LPAwebsite.org.uk/article4direction1.pdf`
The URL of the webpage on your website that introduces the document.
-Each document should be linked to from a documentation webpage that includes a short description of the data and the document you’re linking to. Each article 4 direction should have a unique URL. This means you can create a separate page for each one, or you could list several on one page. If you do that, there must be a separate anchor link (fragment identifier) for each one.
+Each document should be linked to from a documentation webpage that includes a short description of the data and the document you’re linking to. Each article 4 direction should have a unique URL. This means you can create a separate page for each one, or you could list several on one page. If you do that, there must be a separate anchor link (fragment identifier) for each one.
This means each section of your page should have its own URL. Most publishing systems will allow you to use a hashtag to create the identifiers for each article 4 direction you list - as in the examples shown.
@@ -168,7 +181,7 @@ A list of the permitted development rights withdrawn by the article 4 direction.
Separate the rights in the list using semicolons.
-Only use rights from our [permitted development right dataset](https://www.planning.data.gov.uk/dataset/permitted-development-right). If the area withdraws a permitted development right that is not in our dataset, email [digitalland@levellingup.gov.uk](digitalland@levellingup.gov.uk).
+Only use rights from our [permitted development right dataset](https://www.planning.data.gov.uk/dataset/permitted-development-right). If the area withdraws a permitted development right that is not in our dataset, email [digitalland@communities.gov.uk](digitalland@communities.gov.uk).
Example: `3D;3M;11B`
diff --git a/application/templates/pages/guidance/specifications/conservation-area.md b/application/templates/pages/guidance/specifications/conservation-area.md
index 49ef3228..46175781 100644
--- a/application/templates/pages/guidance/specifications/conservation-area.md
+++ b/application/templates/pages/guidance/specifications/conservation-area.md
@@ -2,7 +2,7 @@ There are 2 datasets you must provide for conservation area data:
* [conservation area dataset](https://www.planning.data.gov.uk/guidance/specifications/conservation-area#conservation-area-dataset)
* [conservation area document dataset](https://www.planning.data.gov.uk/guidance/specifications/conservation-area#conservation-area-documents-dataset)
-
+
## Format
You can provide data in one of these formats:
@@ -11,9 +11,21 @@ You can provide data in one of these formats:
* GeoJSON
* GML
* Geopackage
-
+
These may be uploaded to a single URL, or served via an OGC WFS or ArcGIS API.
+## Field names
+
+You can provide fields names using hyphens, underscores or spaces.
+
+For example:
+
+* `start-date`
+* `start_date`
+* `start date`
+
+These are all valid, and any uppercase characters will be converted to lowercase.
+
## Conservation area dataset
This dataset is about conservation areas. These are areas of special architectural or historic interest with a character or appearance that must be preserved or enhanced.
@@ -50,7 +62,7 @@ If you’re providing geometry in a GeoJSON, GML or Geopackage, use the associat
The date that the conservation area was officially designated, written in YYYY-MM-DD format.
-Example:
+Example:
`1984-03-28`
@@ -78,7 +90,7 @@ Examples:
One conservation area per page:
`http://www.LPAwebsite.org.uk/data/conservationareas/smithroad`
-More than one conservation area per page with an anchor link for each one:
+More than one conservation area per page with an anchor link for each one:
`http://www.LPAwebsite.org.uk/data/conservationareas#smithroad`
@@ -99,11 +111,11 @@ If the entity has never been updated, enter the same date as start-date.
Write in YYYY-MM-DD format.
-Example:
+Example:
`2022-12-20`
-With dates, some data is better than no data, so:
+With dates, some data is better than no data, so:
* `2022` is fine
* `2022-12` is better
@@ -113,7 +125,7 @@ With dates, some data is better than no data, so:
The date the validity of the record starts, written in YYYY-MM-DD format. Usually, this will be the same as the designation date. If anything about the conservation area has changed, for example, the boundary, it should be the date of that change.
-Example:
+Example:
`1984-04-25`
@@ -127,7 +139,7 @@ With dates, some data is better than no data, so:
Where the conservation area is no longer valid, this should be the date that it was no longer in effect, written in YYYY-MM-DD format. If this does not apply, leave the cell blank.
-Example:
+Example:
`1999-01-20`
@@ -151,7 +163,7 @@ These documents are the authoritative source and provide the context around the
* notices of conservation area designations
* management plans
* gazette entries
-
+
Don’t worry if you don’t have all the data we’ve asked for available right now. If you give us what you’ve got, we can help you fill in the gaps later.
A complete record should contain the following fields (columns):
@@ -162,7 +174,7 @@ A reference or ID for each document that is:
* unique within your dataset
* permanent - it doesn't change when the dataset is updated
-
+
If you don't use a reference already, you will need to create one. This can be a short set of letters or numbers.
Example: `CADOC01`
@@ -212,7 +224,7 @@ If the entity has never been updated, enter the same date as start-date.
Write in YYYY-MM-DD format.
-Example:
+Example:
`1984-03-28`
@@ -226,7 +238,7 @@ With dates, some data is better than no data, so:
The date the document was published, written in YYYY-MM-DD format.
-Example:
+Example:
`1984-03-28`
@@ -240,7 +252,7 @@ With dates, some data is better than no data, so:
The date the document was withdrawn or superseded by another document, written in YYYY-MM-DD format. Leave this blank if the document is still relevant to planning.
-Example:
+Example:
`1984-03-28`
@@ -249,5 +261,3 @@ With dates, some data is better than no data, so:
* `1984` is fine
* `1984-03` is better
* `1984-03-28` is brilliant
-
-
diff --git a/application/templates/pages/guidance/specifications/listed-building.md b/application/templates/pages/guidance/specifications/listed-building.md
index ef338e93..70f9a9d0 100644
--- a/application/templates/pages/guidance/specifications/listed-building.md
+++ b/application/templates/pages/guidance/specifications/listed-building.md
@@ -19,6 +19,18 @@ You can provide data in one of these formats:
These may be uploaded to a single URL, or served via an OGC WFS or ArcGIS API.
+## Field names
+
+You can provide fields names using hyphens, underscores or spaces.
+
+For example:
+
+* `start-date`
+* `start_date`
+* `start date`
+
+These are all valid, and any uppercase characters will be converted to lowercase.
+
Listed buildings outline dataset
------------------------
diff --git a/application/templates/pages/guidance/specifications/tree-preservation-order.md b/application/templates/pages/guidance/specifications/tree-preservation-order.md
index 446fda1c..fcc940a3 100644
--- a/application/templates/pages/guidance/specifications/tree-preservation-order.md
+++ b/application/templates/pages/guidance/specifications/tree-preservation-order.md
@@ -24,6 +24,18 @@ You can provide the zone and individual tree data in one of these formats:
These may be uploaded to a single URL, or served via an OGC WFS or ArcGIS API.
+## Field names
+
+You can provide fields names using hyphens, underscores or spaces.
+
+For example:
+
+* `start-date`
+* `start_date`
+* `start date`
+
+These are all valid, and any uppercase characters will be converted to lowercase.
+
Tree preservation order dataset
-------------------------------
diff --git a/application/templates/partials/footer.html b/application/templates/partials/footer.html
index 238eaa90..98207564 100644
--- a/application/templates/partials/footer.html
+++ b/application/templates/partials/footer.html
@@ -5,6 +5,7 @@
"items": [
{"href": "/service-status", "text": "Service status"},
{"href": "/about/roadmap", "text": "Roadmap"},
+ {"href": "/about/performance", "text": "Performance"},
{"href": "/accessibility-statement", "text": "Accessibility statement"},
],
"html": 'Built by the ',
diff --git a/application/templates/partials/mast-head.html b/application/templates/partials/mast-head.html
index 8521610e..c7b7fe6e 100644
--- a/application/templates/partials/mast-head.html
+++ b/application/templates/partials/mast-head.html
@@ -24,10 +24,14 @@
},
{
"href": "/docs",
- "text": "Documentation"
+ "text": "API"
},
{
- "href": "/guidance",
+ "href": "https://design.planning.data.gov.uk",
+ "text": "Design data"
+ },
+ {
+ "href": "https://check.planning.data.gov.uk/manage",
"text": "Provide data"
},
]
diff --git a/package.json b/package.json
index e8ca351f..21970ff2 100644
--- a/package.json
+++ b/package.json
@@ -21,7 +21,7 @@
"jinja",
"FastAPI"
],
- "author": "planning.data.gov.uk Team - DLUHC",
+ "author": "planning.data.gov.uk Team - MHCLG",
"license": "MIT",
"bugs": {
"url": "https://github.com/digital-land/digital-land.info/issues"
diff --git a/tests/acceptance/test_acceptance.py b/tests/acceptance/test_acceptance.py
index c3401234..58c71fac 100644
--- a/tests/acceptance/test_acceptance.py
+++ b/tests/acceptance/test_acceptance.py
@@ -30,7 +30,7 @@ def test_acceptance(
page.click("text=Datasets")
assert page.url == f"{server_url}/dataset/"
- page.click("text=Documentation")
+ page.click("text=API")
assert page.url == f"{server_url}/docs"
assert page.text_content("h1") == "Documentation"
page.goto(server_url)
@@ -61,7 +61,7 @@ def test_get_healthcheck(server_url):
def test_documentation_page(server_url, page: Page):
page.goto(server_url)
expect(page).to_have_title(re.compile("Planning Data"))
- documentation = page.get_by_role("link", name="Documentation", exact=True)
+ documentation = page.get_by_role("link", name="API", exact=True)
expect(documentation).to_have_attribute("href", "/docs")
documentation.click()
diff --git a/tests/acceptance/test_documentation.py b/tests/acceptance/test_documentation.py
index c4a594f9..d6b7c695 100644
--- a/tests/acceptance/test_documentation.py
+++ b/tests/acceptance/test_documentation.py
@@ -13,7 +13,7 @@ def test_docs_page_loads_ok(server_url, page):
def test_accessing_the_openAPI_file_and_the_swagger_editor(server_url, page):
page.goto(server_url)
- page.get_by_role("link", name="Documentation", exact=True).click()
+ page.get_by_role("link", name="API", exact=True).click()
with page.expect_navigation() as navigation_info:
page.get_by_role(
diff --git a/tests/acceptance/test_search.py b/tests/acceptance/test_search.py
index 78fdbb68..91d47ddd 100644
--- a/tests/acceptance/test_search.py
+++ b/tests/acceptance/test_search.py
@@ -201,3 +201,31 @@ def test_entity_search_field_paramter_selects_correct_fields(
assert (
field in entity.keys()
), f"Expected field:{field} is not in the output fields:{entity.keys()}"
+
+
+@pytest.mark.parametrize("extension_param", [("json"), ("geojson")])
+def test_extension_query_parameter_ignored(
+ extension_param, db_session, test_data: dict, client, exclude_middleware
+):
+ db_session.query(EntityOrm).delete()
+ db_session.commit()
+
+ for entity_data in test_data["entities"]:
+ db_session.add(EntityOrm(**entity_data))
+ db_session.commit()
+
+ response = client.get(
+ f"/entity/?dataset=conservation-area&extension={extension_param}",
+ allow_redirects=False,
+ )
+
+ assert (
+ "text/html" in response.headers["Content-Type"]
+ ), "Expected response in text/html format"
+ assert response.status_code == 200, f"Expected 200 but got {response.status_code}"
+ if "application/json" in response.headers["Content-Type"]:
+ response_json = response.json()
+ assert "entities" in response_json, "Expected 'entities' key in JSON response"
+ assert isinstance(
+ response_json["entities"], list
+ ), "'entities' should be a list"
diff --git a/tests/unit/routers/test_entity.py b/tests/unit/routers/test_entity.py
index ed61891a..2ea1b645 100644
--- a/tests/unit/routers/test_entity.py
+++ b/tests/unit/routers/test_entity.py
@@ -537,7 +537,9 @@ def test_search_entities_no_entities_returned_no_query_params_json(mocker):
mocker.patch(
"application.routers.entity.get_typology_names", return_value=["geography"]
)
+
request = MagicMock()
+ request.query_params.get.return_value = None
extension = MagicMock()
extension.value = "json"
result = search_entities(
@@ -566,6 +568,7 @@ def test_search_entities_no_entities_returned_no_query_params_geojson(mocker):
"application.routers.entity.get_typology_names", return_value=["geography"]
)
request = MagicMock()
+ request.query_params.get.return_value = None
extension = MagicMock()
extension.value = "geojson"
result = search_entities(
@@ -654,6 +657,7 @@ def test_search_entities_multiple_entities_returned_no_query_params_json(
"application.routers.entity.get_typology_names", return_value=["geography"]
)
request = MagicMock()
+ request.query_params.get.return_value = None
extension = MagicMock()
extension.value = "json"
result = search_entities(
@@ -688,6 +692,7 @@ def test_search_entities_multiple_entities_returned_no_query_params_geojson(
"application.routers.entity.get_typology_names", return_value=["geography"]
)
request = MagicMock()
+ request.query_params.get.return_value = None
extension = MagicMock()
extension.value = "geojson"
result = search_entities(
@@ -703,67 +708,48 @@ def test_search_entities_multiple_entities_returned_no_query_params_geojson(
assert "features" in result, "expected features attribute"
-def test_search_entities_exclude_field(mocker, multiple_entity_models):
- exclude_field = ["geojson"]
-
- mocker.patch(
- "application.routers.entity.get_entity_search",
- return_value={
- "params": normalised_params(
- asdict(QueryFilters(exclude_field=exclude_field))
- ),
- "count": len(multiple_entity_models),
- "entities": multiple_entity_models,
- },
- )
- mocker.patch(
- "application.routers.entity.get_dataset_names",
- return_value=["ancient-woodland"],
- )
- mocker.patch(
- "application.routers.entity.get_typology_names", return_value=["geography"]
- )
-
+@pytest.mark.parametrize("extension_value", [("json"), ("geojson"), (None)])
+def test_search_entities_with_query_extension(
+ mocker, extension_value, multiple_entity_models
+):
request = MagicMock()
+ request.query_params.get.return_value = extension_value
extension = MagicMock()
- extension.value = "json"
-
- result = search_entities(
- request=request,
- query_filters=QueryFilters(exclude_field=exclude_field),
- extension=extension,
- )
-
- assert "geojson" not in result["entities"][0]
+ extension.value = extension_value
-
-def test_search_entities_no_exclude_field(mocker, multiple_entity_models):
+ normalised_query_params = normalised_params(asdict(QueryFilters()))
mocker.patch(
"application.routers.entity.get_entity_search",
return_value={
- "params": normalised_params(asdict(QueryFilters())),
- "count": len(multiple_entity_models),
+ "params": normalised_query_params,
+ "count": 0,
"entities": multiple_entity_models,
},
)
-
mocker.patch(
"application.routers.entity.get_dataset_names",
- return_value=["ancient-woodland"],
+ return_value=["dataset1"],
)
mocker.patch(
- "application.routers.entity.get_typology_names", return_value=["geography"]
+ "application.routers.entity.get_typology_names",
+ return_value=["typology1"],
+ )
+ mock_get_session = mocker.patch(
+ "application.routers.entity.get_session", return_value=MagicMock()
)
-
- request = MagicMock()
- extension = MagicMock()
- extension.value = "json"
result = search_entities(
request=request,
- query_filters=QueryFilters(exclude_field=None),
+ query_filters=QueryFilters(),
extension=extension,
+ session=mock_get_session.return_value,
)
-
- for entity in result["entities"]:
- assert "geometry" in entity
+ try:
+ result.template.render(result.context)
+ assert True
+ except Exception:
+ if hasattr(result, "context"):
+ logging.warning(f"context:{result.context}")
+ else:
+ logging.warning("result has no context")
+ assert False, "template unable to render, missing variable(s) from context"