mirror of
https://github.com/CatimaLoyalty/Android.git
synced 2026-01-24 14:58:07 -05:00
Remove file arg from TaskCompleteListener
Soon more than files will be imported, as content URIs will also be supported. This then makes the File argument for onTaskComplete() not always useful, as there may not be a direct file used. To this end, removing the File argument as the caller should know what was passed to the ImportExport task anyway.
This commit is contained in:
@@ -211,12 +211,10 @@ public class ImportExportTest
|
||||
class TestTaskCompleteListener implements ImportExportTask.TaskCompleteListener
|
||||
{
|
||||
Boolean success;
|
||||
File file;
|
||||
|
||||
public void onTaskComplete(boolean success, File file)
|
||||
public void onTaskComplete(boolean success)
|
||||
{
|
||||
this.success = success;
|
||||
this.file = file;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -244,8 +242,6 @@ public class ImportExportTest
|
||||
// Check that the listener was executed
|
||||
assertNotNull(listener.success);
|
||||
assertEquals(true, listener.success);
|
||||
assertNotNull(listener.file);
|
||||
assertEquals(exportFile, listener.file);
|
||||
|
||||
clearDatabase();
|
||||
|
||||
@@ -262,8 +258,6 @@ public class ImportExportTest
|
||||
// Check that the listener was executed
|
||||
assertNotNull(listener.success);
|
||||
assertEquals(true, listener.success);
|
||||
assertNotNull(listener.file);
|
||||
assertEquals(exportFile, listener.file);
|
||||
|
||||
assertEquals(NUM_CARDS, db.getLoyaltyCardCount());
|
||||
|
||||
|
||||
Reference in New Issue
Block a user