TwitterContext extends ContextWrapper { @Override public SQLiteDatabase openOrCreateDatabase(String name, int mode, SQLiteDatabase.CursorFactory factory) { return android.database.sqlite.SQLiteDatabase.openOrCreateDatabase( getDatabasePath(name), factory); } TwitterContext(Context base, String componentName, String componentPath); @Override File getDatabasePath(String name); @Override SQLiteDatabase openOrCreateDatabase(String name, int mode,
            SQLiteDatabase.CursorFactory factory); @Override SQLiteDatabase openOrCreateDatabase(String name, int mode,
            SQLiteDatabase.CursorFactory factory, DatabaseErrorHandler errorHandler); @Override File getFilesDir(); @Override File getExternalFilesDir(String type); @Override File getCacheDir(); @Override File getExternalCacheDir(); @Override SharedPreferences getSharedPreferences(String name, int mode);  }
@Test public void testOpenOrCreateDatabase() { final SQLiteDatabase db = context.openOrCreateDatabase("b", Context.MODE_PRIVATE, null); assertNotNull(db); }
@Test public void testOpenOrCreateDatabaseWithErrorHandler() { final SQLiteDatabase db = context.openOrCreateDatabase("b", Context.MODE_PRIVATE, null, null); assertNotNull(db); }