fix: add missing fixtures and improve test model constructor
- Add oauth_db_session fixture for OAuth tests - Add simple_user fixture for test data - Fix TestModel constructor to avoid pytest warning - Improve test isolation and cleanup
This commit is contained in:
@@ -18,6 +18,10 @@ class TestModel(Base):
|
||||
id = Column(Integer, primary_key=True)
|
||||
name = Column(String)
|
||||
description = Column(String, nullable=True)
|
||||
|
||||
def __init__(self, name: str = None, description: str = None):
|
||||
self.name = name
|
||||
self.description = description
|
||||
|
||||
class TestDatabaseFunctions:
|
||||
"""Тесты для функций работы с базой данных"""
|
||||
|
||||
Reference in New Issue
Block a user