Fixed reminder services leaving junk for all of the other services to deal with, bump version in Android manifest

pull/14/head
Tim Su 16 years ago
parent 73d15ccd56
commit 98273affd6

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" <manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.timsu.astrid" package="com.timsu.astrid"
android:versionName="3.0.7" android:versionCode="146" android:versionName="3.1.0" android:versionCode="146"
android:installLocation="internalOnly"> android:installLocation="internalOnly">
<!-- widgets, alarms, and services will break if Astrid is installed on SD card --> <!-- widgets, alarms, and services will break if Astrid is installed on SD card -->

@ -11,6 +11,7 @@ import com.todoroo.astrid.utility.Preferences;
public class ReminderServiceTests extends DatabaseTestCase { public class ReminderServiceTests extends DatabaseTestCase {
ReminderService service; ReminderService service;
AlarmScheduler original;
@Autowired @Autowired
TaskDao taskDao; TaskDao taskDao;
@ -19,9 +20,16 @@ public class ReminderServiceTests extends DatabaseTestCase {
protected void setUp() throws Exception { protected void setUp() throws Exception {
super.setUp(); super.setUp();
service = ReminderService.getInstance(); service = ReminderService.getInstance();
original = service.getScheduler();
Preferences.setPreferenceDefaults(); Preferences.setPreferenceDefaults();
} }
@Override
protected void tearDown() throws Exception {
super.tearDown();
service.setScheduler(original);
}
/** tests with no alarms */ /** tests with no alarms */
public void testNoReminders() { public void testNoReminders() {
service.setScheduler(new NoAlarmExpected()); service.setScheduler(new NoAlarmExpected());

Loading…
Cancel
Save