I am writing unit tests for my SwiftData application. Currently, I am using in-memory database, which get reset after every test. What benefits will I gain if I start using real database? My main reason is that real database (SQLite) will be the environment user will experience. I can easily wipe out the records from the real database after each test is completed.
Are there are scenario where running in-memory test will produce a different result as compared to running the test with real database? Am I ignoring and not capturing those scenarios by running it in-memory?
PS: I used the term unit tests. You can use integration test if that makes you feel better 🙂
New contributor