Import Loop DB without app restart

This commit is contained in:
2017-06-23 10:21:12 -04:00
parent 33f7acc9ca
commit 8ccada67d6
10 changed files with 43 additions and 37 deletions

View File

@@ -37,8 +37,6 @@ import java.io.*;
import java.sql.*;
import java.util.*;
import sun.reflect.generics.reflectiveObjects.*;
import static org.mockito.Mockito.*;
@RunWith(MockitoJUnitRunner.class)
@@ -73,12 +71,6 @@ public class BaseUnitTest
throw new RuntimeException(e);
}
}
@Override
public File getProductionDatabaseFile()
{
throw new NotImplementedException();
}
};
@Before

View File

@@ -60,7 +60,6 @@ public class ImportTest extends BaseUnitTest
}
@Test
@Ignore
public void testLoopDB() throws IOException
{
importFromFile("loop.db");
@@ -133,7 +132,7 @@ public class ImportTest extends BaseUnitTest
assertTrue(file.canRead());
GenericImporter importer = new GenericImporter(habitList,
new LoopDBImporter(habitList, databaseOpener),
new LoopDBImporter(habitList, modelFactory, databaseOpener),
new RewireDBImporter(habitList, modelFactory, databaseOpener),
new TickmateDBImporter(habitList, modelFactory, databaseOpener),
new HabitBullCSVImporter(habitList, modelFactory));