diff --git a/src/openeo_aggregator/config.py b/src/openeo_aggregator/config.py index 7ae8fa4c..315a978d 100644 --- a/src/openeo_aggregator/config.py +++ b/src/openeo_aggregator/config.py @@ -126,7 +126,7 @@ def get_config(x: Union[str, Path, AggregatorConfig, None] = None) -> Aggregator class AggregatorBackendConfig(OpenEoBackendConfig): # TODO #112 migrate everything from AggregatorConfig to this class - capabilities_backend_version = openeo_aggregator.about.__version__ - capabilities_deploy_metadata = build_backend_deploy_metadata( + capabilities_backend_version: str = openeo_aggregator.about.__version__ + capabilities_deploy_metadata: dict = build_backend_deploy_metadata( packages=["openeo", "openeo_driver", "openeo_aggregator"], ) diff --git a/tests/test_views.py b/tests/test_views.py index 33e3b2bb..dbc2b997 100644 --- a/tests/test_views.py +++ b/tests/test_views.py @@ -26,6 +26,7 @@ RegexMatcher, ) +import openeo_aggregator.about from openeo_aggregator.config import AggregatorConfig, get_config_dir from openeo_aggregator.constants import JOB_OPTION_FORCE_BACKEND from openeo_aggregator.metadata import ( @@ -42,6 +43,7 @@ def test_capabilities(self, api100): res = api100.get("/").assert_status_code(200) capabilities = res.json assert capabilities["api_version"] == "1.0.0" + assert capabilities["backend_version"] == openeo_aggregator.about.__version__ endpoints = capabilities["endpoints"] assert {"methods": ["GET"], "path": "/collections"} in endpoints assert {"methods": ["GET"], "path": "/collections/{collection_id}"} in endpoints @@ -73,6 +75,11 @@ def test_billing_plans(self, api100): assert "early-adopter" in plans assert plans["early-adopter"]["paid"] is True + def test_deploy_metadata(self, api100): + capabilities = api100.get("/").assert_status_code(200).json + assert "openeo_aggregator" in capabilities["processing:software"] + + def test_only_oidc_auth(self, api100): res = api100.get("/").assert_status_code(200) capabilities = res.json