I’m trying to mock database access (OrmLiteSqliteOpenHelper).
I just need a piece of information or some example how to achieve that.
I tried to create OrmLiteSqliteOpenHelper with IsolatedContext, but after running the code, Android just uses the standard context.
If you check here you will see an answer for at least the latter part of your question: you need to extend InstrumentationTestCase rather than AndroidTestCase and call getInstrumentation().getContext() to get the context of the test application. However I have never used OrmLiteSqliteOpenHelper and do not know whether it will help to mock a database. Actually, I am also searching for a way to mock.