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:
2025-08-12 13:28:58 +03:00
parent aad8c7b3d5
commit 25ec1ba797
2 changed files with 42 additions and 0 deletions

View File

@@ -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:
"""Тесты для функций работы с базой данных"""