Once again, I haven't used SQLite in a very long time nor do I know anything about what your code looks like but there's a possibility that if you remove your calls to SQLite from your unit tests and use a mock repository, you could reduce that total run-time of your tests from 20 seconds to a second.
One of my current asp.net mvc projects has about 192 unit tests and has a total run-time around 2.3 seconds. Most of the time, the code I'm changing and working on doesn't interact with the database and so I can keep running all my unit-tests after every change to make sure I haven't broken anything. I wouldn't be running my unit-tests as regularly as I do now if I knew I'd have to wait 20 seconds each time.
Give trying using a mock for the test that involve SQLite when you find some free time. You may find the time saved to be worth it. I'd also suggest looking into dan_b's suggestion below; a one-line code change to go from in-memory to integration tests sounds interesting and if it works like I imagine it does, I think I'll be giving nHibernate another chance since my last disappointing attempt at using it.
Appreciate it, thanks. I definitely have tests that run instantly because they just use a mocked database, and ideally all of my tests would do that because I agree having them run instantly is so much better than waiting around.
I'm going to be more attentive to how long tests take from now on, and try and avoid a backed DB when possible. Thanks!
One of my current asp.net mvc projects has about 192 unit tests and has a total run-time around 2.3 seconds. Most of the time, the code I'm changing and working on doesn't interact with the database and so I can keep running all my unit-tests after every change to make sure I haven't broken anything. I wouldn't be running my unit-tests as regularly as I do now if I knew I'd have to wait 20 seconds each time.
Give trying using a mock for the test that involve SQLite when you find some free time. You may find the time saved to be worth it. I'd also suggest looking into dan_b's suggestion below; a one-line code change to go from in-memory to integration tests sounds interesting and if it works like I imagine it does, I think I'll be giving nHibernate another chance since my last disappointing attempt at using it.