Skip to content

Testing FastAPI CRUD operations with SQLModel instead of SQLAlchmey #673

Discussion options

You must be logged in to vote

You have a fixture that's yielding a connection to an in memory database, but you aren't doing anything with it. You'll have to override how your app interacts with the database to tell it to use the in memory database rather than the normal one. There is an example how to do that here https://sqlmodel.tiangolo.com/tutorial/fastapi/tests/

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by YuriiMotov
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
2 participants