From 7b78383fee477ea60bde610661660a148a7d9955 Mon Sep 17 00:00:00 2001 From: tammy-baylis-swi Date: Wed, 13 Nov 2024 16:00:27 -0800 Subject: [PATCH] Fix test for sqlalchemy 2 --- .../tests/test_sqlcommenter.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/instrumentation/opentelemetry-instrumentation-sqlalchemy/tests/test_sqlcommenter.py b/instrumentation/opentelemetry-instrumentation-sqlalchemy/tests/test_sqlcommenter.py index 921abdc600..8490721e3e 100644 --- a/instrumentation/opentelemetry-instrumentation-sqlalchemy/tests/test_sqlcommenter.py +++ b/instrumentation/opentelemetry-instrumentation-sqlalchemy/tests/test_sqlcommenter.py @@ -70,7 +70,7 @@ def test_sqlcommenter_enabled_matches_db_statement_attribute(self): commenter_options={"db_framework": False}, ) cnx = engine.connect() - cnx.execute("SELECT 1;").fetchall() + cnx.execute(text("SELECT 1;")).fetchall() query_log = self.caplog.records[-2].getMessage() self.assertRegex( query_log,