mirror of
https://github.com/fastapi-users/fastapi-users.git
synced 2025-11-02 04:05:19 +08:00
Reorganize base modules
This commit is contained in:
@ -6,14 +6,14 @@ import sqlalchemy
|
||||
from databases import Database
|
||||
from sqlalchemy.ext.declarative import DeclarativeMeta, declarative_base
|
||||
|
||||
from fastapi_users.db.sqlalchemy import BaseUserTable, SQLAlchemyUserDatabase
|
||||
from fastapi_users.db.sqlalchemy import SQLAlchemyBaseUserTable, SQLAlchemyUserDatabase
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
async def sqlalchemy_user_db() -> AsyncGenerator[SQLAlchemyUserDatabase, None]:
|
||||
Base: DeclarativeMeta = declarative_base()
|
||||
|
||||
class User(BaseUserTable, Base):
|
||||
class User(SQLAlchemyBaseUserTable, Base):
|
||||
pass
|
||||
|
||||
DATABASE_URL = "sqlite:///./test.db"
|
||||
|
||||
Reference in New Issue
Block a user