mirror of
https://github.com/sudoxnym/habitica-android.git
synced 2026-05-19 20:29:02 +00:00
fix realm issue in tests
This commit is contained in:
parent
44977a4d10
commit
fb18520da6
2 changed files with 5 additions and 2 deletions
|
|
@ -145,7 +145,11 @@ public abstract class HabiticaBaseApplication extends MultiDexApplication {
|
|||
RealmConfiguration.Builder builder = new RealmConfiguration.Builder()
|
||||
.schemaVersion(1)
|
||||
.deleteRealmIfMigrationNeeded();
|
||||
Realm.setDefaultConfiguration(builder.build());
|
||||
try {
|
||||
Realm.setDefaultConfiguration(builder.build());
|
||||
} catch (UnsatisfiedLinkError ignored) {
|
||||
//Catch crash in tests
|
||||
}
|
||||
}
|
||||
|
||||
private void checkIfNewVersion() {
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@ import io.realm.RealmList;
|
|||
import static org.junit.Assert.assertEquals;
|
||||
|
||||
@Config(constants = BuildConfig.class)
|
||||
@RunWith(RobolectricTestRunner.class)
|
||||
public class UserTest {
|
||||
|
||||
private User user;
|
||||
|
|
|
|||
Loading…
Reference in a new issue