mirror of
https://github.com/iSoron/uhabits.git
synced 2025-12-06 01:08:50 -06:00
Minor refactoring
This commit is contained in:
@@ -21,7 +21,6 @@ package org.isoron.uhabits.unit.views;
|
||||
|
||||
import android.support.test.runner.AndroidJUnit4;
|
||||
import android.test.suitebuilder.annotation.SmallTest;
|
||||
import android.util.Log;
|
||||
|
||||
import org.isoron.uhabits.helpers.DateHelper;
|
||||
import org.isoron.uhabits.models.Habit;
|
||||
@@ -53,14 +52,13 @@ public class HabitHistoryViewTest extends ViewTest
|
||||
|
||||
view = new HabitHistoryView(targetContext);
|
||||
view.setHabit(habit);
|
||||
refreshData(view);
|
||||
measureView(dpToPixels(300), dpToPixels(100), view);
|
||||
refreshData(view);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void render() throws Throwable
|
||||
{
|
||||
Log.d("HabitHistoryViewTest", String.format("height=%d", dpToPixels(100)));
|
||||
assertRenders(view, "HabitHistoryView/render.png");
|
||||
}
|
||||
|
||||
|
||||
@@ -207,10 +207,10 @@ public class CheckmarkList
|
||||
try
|
||||
{
|
||||
SQLiteStatement statement = db.compileStatement(query);
|
||||
statement.bindString(1, habit.getId().toString());
|
||||
|
||||
for (int i = 0; i < timestamps.length; i++)
|
||||
{
|
||||
statement.bindLong(1, habit.getId());
|
||||
statement.bindLong(2, timestamps[i]);
|
||||
statement.bindLong(3, values[i]);
|
||||
statement.execute();
|
||||
|
||||
Reference in New Issue
Block a user