Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrelves2007-01-26 21:22:28 -0500
committerrelves2007-01-26 21:22:28 -0500
commitd986957b63a46e2b55924d30f2980cfbcd009a27 (patch)
tree7d8788321532673b8ddcf4e5cd34106aacedc49f /org.eclipse.mylyn.trac.tests
parent3979024b91f2b858bacd9c3eda81c00b1215f066 (diff)
downloadorg.eclipse.mylyn.tasks-d986957b63a46e2b55924d30f2980cfbcd009a27.tar.gz
org.eclipse.mylyn.tasks-d986957b63a46e2b55924d30f2980cfbcd009a27.tar.xz
org.eclipse.mylyn.tasks-d986957b63a46e2b55924d30f2980cfbcd009a27.zip
NEW - bug 171894: [api] move getChangedSinceLastSync out of taskdatahandler and into AbstractRepositoryConnector
https://bugs.eclipse.org/bugs/show_bug.cgi?id=171894
Diffstat (limited to 'org.eclipse.mylyn.trac.tests')
-rw-r--r--org.eclipse.mylyn.trac.tests/src/org/eclipse/mylyn/trac/tests/TracOfflineTaskHandlerTest.java15
1 files changed, 5 insertions, 10 deletions
diff --git a/org.eclipse.mylyn.trac.tests/src/org/eclipse/mylyn/trac/tests/TracOfflineTaskHandlerTest.java b/org.eclipse.mylyn.trac.tests/src/org/eclipse/mylyn/trac/tests/TracOfflineTaskHandlerTest.java
index feed358a2..157050b10 100644
--- a/org.eclipse.mylyn.trac.tests/src/org/eclipse/mylyn/trac/tests/TracOfflineTaskHandlerTest.java
+++ b/org.eclipse.mylyn.trac.tests/src/org/eclipse/mylyn/trac/tests/TracOfflineTaskHandlerTest.java
@@ -27,7 +27,6 @@ import org.eclipse.mylar.internal.trac.core.ITracClient.Version;
import org.eclipse.mylar.internal.trac.core.model.TracTicket;
import org.eclipse.mylar.internal.trac.core.model.TracTicket.Key;
import org.eclipse.mylar.tasks.core.AbstractRepositoryTask;
-import org.eclipse.mylar.tasks.core.ITaskDataHandler;
import org.eclipse.mylar.tasks.core.TaskRepository;
import org.eclipse.mylar.tasks.core.TaskRepositoryManager;
import org.eclipse.mylar.tasks.ui.TasksUiPlugin;
@@ -41,8 +40,6 @@ public class TracOfflineTaskHandlerTest extends TestCase {
private TracRepositoryConnector connector;
- private ITaskDataHandler offlineHandler;
-
private TaskRepository repository;
private TaskRepositoryManager manager;
@@ -63,8 +60,6 @@ public class TracOfflineTaskHandlerTest extends TestCase {
connector = (TracRepositoryConnector) manager.getRepositoryConnector(TracCorePlugin.REPOSITORY_KIND);
TasksUiPlugin.getSynchronizationManager().setForceSyncExec(true);
-
- offlineHandler = connector.getTaskDataHandler();
}
protected void init(String url, Version version) {
@@ -87,7 +82,7 @@ public class TracOfflineTaskHandlerTest extends TestCase {
tasks.add(task);
assertEquals(null, repository.getSyncTimeStamp());
- Set<AbstractRepositoryTask> result = offlineHandler.getChangedSinceLastSync(repository, tasks);
+ Set<AbstractRepositoryTask> result = connector.getChangedSinceLastSync(repository, tasks);
assertEquals(tasks, result);
assertEquals(null, repository.getSyncTimeStamp());
@@ -106,16 +101,16 @@ public class TracOfflineTaskHandlerTest extends TestCase {
tasks.add(task);
assertEquals(null, repository.getSyncTimeStamp());
- Set<AbstractRepositoryTask> result = offlineHandler.getChangedSinceLastSync(repository, tasks);
+ Set<AbstractRepositoryTask> result = connector.getChangedSinceLastSync(repository, tasks);
assertEquals(tasks, result);
// always returns the ticket because time comparison mode is >=
repository.setSyncTimeStamp(lastModified + "");
- result = offlineHandler.getChangedSinceLastSync(repository, tasks);
+ result = connector.getChangedSinceLastSync(repository, tasks);
assertEquals(tasks, result);
repository.setSyncTimeStamp((lastModified + 1) + "");
- result = offlineHandler.getChangedSinceLastSync(repository, tasks);
+ result = connector.getChangedSinceLastSync(repository, tasks);
assertTrue(result.isEmpty());
// change ticket making sure it gets a new change time
@@ -130,7 +125,7 @@ public class TracOfflineTaskHandlerTest extends TestCase {
client.updateTicket(ticket, "comment");
repository.setSyncTimeStamp((lastModified + 1) + "");
- result = offlineHandler.getChangedSinceLastSync(repository, tasks);
+ result = connector.getChangedSinceLastSync(repository, tasks);
assertEquals(tasks, result);
}

Back to the top