From c6b26cc09d18edc3886bf2140b0de7682a4dd769 Mon Sep 17 00:00:00 2001 From: Christoph Ladurner Date: Thu, 12 Dec 2024 14:41:02 +0100 Subject: [PATCH] comp: make compatible to flask-sqlalchemy>=3.1 --- tests/test_alembic.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/test_alembic.py b/tests/test_alembic.py index 1fea19c8..20910fef 100644 --- a/tests/test_alembic.py +++ b/tests/test_alembic.py @@ -3,6 +3,7 @@ # This file is part of Invenio. # Copyright (C) 2021 TU Wien. # Copyright (C) 2021 Northwestern University. +# Copyright (C) 2024 Graz University of Technology. # # Invenio is free software; you can redistribute it and/or modify it # under the terms of the MIT License; see LICENSE file for more details. @@ -46,7 +47,7 @@ def test_alembic(app, database): raise pytest.skip("Upgrades are not supported on SQLite.") # Check that this package's SQLAlchemy models have been properly registered - tables = [x.name for x in db.get_tables_for_bind()] + tables = [x for x in db.metadata.tables] assert "vocabularies_metadata" in tables assert "vocabularies_types" in tables assert "vocabularies_schemes" in tables