X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/d97ca9fcb2ae54080d6b92c7e85ff111308bc1cc..5a61d3d5f6ff1b0c9fe1d5d10c594033d40d5856:/test/python/api/fake_adaptor.py diff --git a/test/python/api/fake_adaptor.py b/test/python/api/fake_adaptor.py index f04381db..4b64c17d 100644 --- a/test/python/api/fake_adaptor.py +++ b/test/python/api/fake_adaptor.py @@ -2,15 +2,16 @@ # # This file is part of Nominatim. (https://nominatim.org) # -# Copyright (C) 2023 by the Nominatim developer community. +# Copyright (C) 2024 by the Nominatim developer community. # For a full list of authors see the git log. """ Provides dummy implementations of ASGIAdaptor for testing. """ from collections import namedtuple -import nominatim.api.v1.server_glue as glue -from nominatim.config import Configuration +import nominatim_api.v1.server_glue as glue +from nominatim_api.v1.format import dispatch as formatting +from nominatim_api.config import Configuration class FakeError(BaseException): @@ -47,6 +48,13 @@ class FakeAdaptor(glue.ASGIAdaptor): return FakeResponse(status, output, self.content_type) + def base_uri(self): + return 'http://test' + def config(self): return self._config + def formatting(self): + return formatting + +