Skip to content

Commit

Permalink
fix: simplify test connection query
Browse files Browse the repository at this point in the history
  • Loading branch information
nextchamp-saqib committed Oct 9, 2023
1 parent f4313b9 commit 1a13be9
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@ def __init__(self):
self.table_factory = None

def test_connection(self):
return self.execute_query("SELECT 1")
with self.connect() as connection:
connection.execute(text("SELECT 1"))

def connect(self):
try:
Expand Down

0 comments on commit 1a13be9

Please sign in to comment.