FastAPI-template
FastAPI-template copied to clipboard
Default generated dummy tests require database but github action provided do not run database
The project should either provide test cases with mocked DAO or run the database in GitHub Actions. I prefer providing mocked tests. This will serve as an example of how to write mocked tests.
Mocked tests are generally a bad idea. Because you want to be sure that everything you write will run on an actual database. Sometimes databases might behave not as you would expect.