]> git.openstreetmap.org Git - nominatim.git/blobdiff - test/bdd/steps/http_responses.py
bdd: move output format computation into response
[nominatim.git] / test / bdd / steps / http_responses.py
index c3cd4f5280d802c78770fc273fd0d76d213673cd..161e29fd7688e8ca2d7d92ad3654e759d569e8d1 100644 (file)
@@ -40,6 +40,10 @@ class GenericResponse:
     """ Common base class for all API responses.
     """
     def __init__(self, page, fmt, errorcode=200):
+        fmt = fmt.strip()
+        if fmt == 'jsonv2':
+            fmt = 'json'
+
         self.page = page
         self.format = fmt
         self.errorcode = errorcode