Skip to content

Commit

Permalink
Remove check_first=True
Browse files Browse the repository at this point in the history
  • Loading branch information
lithomson committed Jan 18, 2024
1 parent 443d35d commit 5956479
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion seq_dbutils/_version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.0.4
1.1.0
4 changes: 2 additions & 2 deletions seq_dbutils/table.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ def __init__(self, engine, table_class):

def drop_table(self):
logging.info(f"Dropping table '{self.table_class.__tablename__}'")
self.table_class.__table__.drop(self.engine, check_first=True)
self.table_class.__table__.drop(self.engine)

def create_table(self):
logging.info(f"Creating table '{self.table_class.__tablename__}'")
self.table_class.__table__.create(self.engine, check_first=True)
self.table_class.__table__.create(self.engine)
4 changes: 2 additions & 2 deletions tests/test_table.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,11 @@ def setUp(self):
@patch('sqlalchemy.schema.Table.drop')
def test_drop_table(self, mock_drop, mock_info):
self.table.drop_table()
mock_drop.assert_called_once_with(self.mock_engine, check_first=True)
mock_drop.assert_called_once_with(self.mock_engine)

@patch('logging.info')
@patch('sqlalchemy.schema.Table.create')
def test_create_table(self, mock_create, mock_info):
self.table.create_table()
mock_create.assert_called_once_with(self.mock_engine, check_first=True)
mock_create.assert_called_once_with(self.mock_engine)

0 comments on commit 5956479

Please sign in to comment.