Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrelves2007-06-07 15:51:36 -0400
committerrelves2007-06-07 15:51:36 -0400
commit85f52afb57c9a3680ccb1a950b99ac74dca5dba5 (patch)
tree07d58a42209440c6b0050b1c3d134e054e84b6e8
parentc8c23ef1a802051c8a3cfec5bb53edd61b8ce960 (diff)
downloadorg.eclipse.mylyn.tasks-85f52afb57c9a3680ccb1a950b99ac74dca5dba5.tar.gz
org.eclipse.mylyn.tasks-85f52afb57c9a3680ccb1a950b99ac74dca5dba5.tar.xz
org.eclipse.mylyn.tasks-85f52afb57c9a3680ccb1a950b99ac74dca5dba5.zip
NEW - bug 161734: [api] clean up schitzophrenia between tasks and hits
https://bugs.eclipse.org/bugs/show_bug.cgi?id=161734
-rw-r--r--org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaRepositoryConnector.java2
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/BugzillaRepositoryConnectorTest.java4
-rw-r--r--org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/AbstractRepositoryConnector.java2
-rw-r--r--org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/connector/MockRepositoryConnector.java2
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/RepositorySynchronizationManager.java2
-rw-r--r--org.eclipse.mylyn.trac.core/src/org/eclipse/mylyn/internal/trac/core/TracRepositoryConnector.java2
-rw-r--r--org.eclipse.mylyn.trac.tests/src/org/eclipse/mylyn/trac/tests/TracTaskDataHandlerTest.java10
7 files changed, 12 insertions, 12 deletions
diff --git a/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaRepositoryConnector.java b/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaRepositoryConnector.java
index c76800c1d..4456f8b8d 100644
--- a/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaRepositoryConnector.java
+++ b/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaRepositoryConnector.java
@@ -225,7 +225,7 @@ public class BugzillaRepositoryConnector extends AbstractRepositoryConnector {
@Override
public Set<AbstractRepositoryTask> getChangedSinceLastSync(TaskRepository repository,
- Set<AbstractRepositoryTask> tasks) throws CoreException {
+ Set<AbstractRepositoryTask> tasks, IProgressMonitor monitor) throws CoreException {
try {
Set<AbstractRepositoryTask> changedTasks = new HashSet<AbstractRepositoryTask>();
diff --git a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/BugzillaRepositoryConnectorTest.java b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/BugzillaRepositoryConnectorTest.java
index 8e21b53b6..66739d6b3 100644
--- a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/BugzillaRepositoryConnectorTest.java
+++ b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/BugzillaRepositoryConnectorTest.java
@@ -386,7 +386,7 @@ public class BugzillaRepositoryConnectorTest extends AbstractBugzillaTest {
TasksUiPlugin.getRepositoryManager().setSyncTime(repository, task5.getLastSyncDateStamp(),
TasksUiPlugin.getDefault().getRepositoriesFilePath());
- Set<AbstractRepositoryTask> changedTasks = connector.getChangedSinceLastSync(repository, tasks);
+ Set<AbstractRepositoryTask> changedTasks = connector.getChangedSinceLastSync(repository, tasks, new NullProgressMonitor());
// Always last known changed returned
assertEquals(1, changedTasks.size());
@@ -414,7 +414,7 @@ public class BugzillaRepositoryConnectorTest extends AbstractBugzillaTest {
submit(task4, taskData4);
submit(task5, taskData5);
- changedTasks = connector.getChangedSinceLastSync(repository, tasks);
+ changedTasks = connector.getChangedSinceLastSync(repository, tasks, new NullProgressMonitor());
assertEquals("Changed reports expected ", 2, changedTasks.size());
assertTrue(tasks.containsAll(changedTasks));
diff --git a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/AbstractRepositoryConnector.java b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/AbstractRepositoryConnector.java
index 214c8d548..827cdca40 100644
--- a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/AbstractRepositoryConnector.java
+++ b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/AbstractRepositoryConnector.java
@@ -262,7 +262,7 @@ public abstract class AbstractRepositoryConnector {
* @throws CoreException
*/
public abstract Set<AbstractRepositoryTask> getChangedSinceLastSync(TaskRepository repository,
- Set<AbstractRepositoryTask> tasks) throws CoreException;
+ Set<AbstractRepositoryTask> tasks, IProgressMonitor monitor) throws CoreException;
/**
* Attaches the associated context to <code>task</code>.
diff --git a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/connector/MockRepositoryConnector.java b/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/connector/MockRepositoryConnector.java
index 6174a89bc..3463dc7e0 100644
--- a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/connector/MockRepositoryConnector.java
+++ b/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/connector/MockRepositoryConnector.java
@@ -133,7 +133,7 @@ public class MockRepositoryConnector extends AbstractRepositoryConnector {
@Override
public Set<AbstractRepositoryTask> getChangedSinceLastSync(TaskRepository repository,
- Set<AbstractRepositoryTask> tasks) throws CoreException {
+ Set<AbstractRepositoryTask> tasks, IProgressMonitor monitor) throws CoreException {
return Collections.emptySet();
}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/RepositorySynchronizationManager.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/RepositorySynchronizationManager.java
index 4dee63fe6..c6f82d452 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/RepositorySynchronizationManager.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/RepositorySynchronizationManager.java
@@ -182,7 +182,7 @@ public class RepositorySynchronizationManager {
.getRepositoryTasks(repository.getUrl()));
try {
- changedTasks = connector.getChangedSinceLastSync(repository, repositoryTasks);
+ changedTasks = connector.getChangedSinceLastSync(repository, repositoryTasks, monitor);
if (changedTasks == null || changedTasks.size() == 0) {
return Status.OK_STATUS;
diff --git a/org.eclipse.mylyn.trac.core/src/org/eclipse/mylyn/internal/trac/core/TracRepositoryConnector.java b/org.eclipse.mylyn.trac.core/src/org/eclipse/mylyn/internal/trac/core/TracRepositoryConnector.java
index 1a9db086f..1bb0aa399 100644
--- a/org.eclipse.mylyn.trac.core/src/org/eclipse/mylyn/internal/trac/core/TracRepositoryConnector.java
+++ b/org.eclipse.mylyn.trac.core/src/org/eclipse/mylyn/internal/trac/core/TracRepositoryConnector.java
@@ -158,7 +158,7 @@ public class TracRepositoryConnector extends AbstractRepositoryConnector {
@Override
public Set<AbstractRepositoryTask> getChangedSinceLastSync(TaskRepository repository,
- Set<AbstractRepositoryTask> tasks) throws CoreException {
+ Set<AbstractRepositoryTask> tasks, IProgressMonitor monitor) throws CoreException {
if (repository.getSyncTimeStamp() == null) {
return tasks;
}
diff --git a/org.eclipse.mylyn.trac.tests/src/org/eclipse/mylyn/trac/tests/TracTaskDataHandlerTest.java b/org.eclipse.mylyn.trac.tests/src/org/eclipse/mylyn/trac/tests/TracTaskDataHandlerTest.java
index 30767ea97..c9af4228a 100644
--- a/org.eclipse.mylyn.trac.tests/src/org/eclipse/mylyn/trac/tests/TracTaskDataHandlerTest.java
+++ b/org.eclipse.mylyn.trac.tests/src/org/eclipse/mylyn/trac/tests/TracTaskDataHandlerTest.java
@@ -85,7 +85,7 @@ public class TracTaskDataHandlerTest extends TestCase {
tasks.add(task);
assertEquals(null, repository.getSyncTimeStamp());
- Set<AbstractRepositoryTask> result = connector.getChangedSinceLastSync(repository, tasks);
+ Set<AbstractRepositoryTask> result = connector.getChangedSinceLastSync(repository, tasks, new NullProgressMonitor());
assertEquals(tasks, result);
assertEquals(null, repository.getSyncTimeStamp());
@@ -115,16 +115,16 @@ public class TracTaskDataHandlerTest extends TestCase {
tasks.add(task);
assertEquals(null, repository.getSyncTimeStamp());
- Set<AbstractRepositoryTask> result = connector.getChangedSinceLastSync(repository, tasks);
+ Set<AbstractRepositoryTask> result = connector.getChangedSinceLastSync(repository, tasks, new NullProgressMonitor());
assertEquals(tasks, result);
// always returns the ticket because time comparison mode is >=
repository.setSyncTimeStamp(lastModified + "");
- result = connector.getChangedSinceLastSync(repository, tasks);
+ result = connector.getChangedSinceLastSync(repository, tasks, new NullProgressMonitor());
assertEquals(tasks, result);
repository.setSyncTimeStamp((lastModified + 1) + "");
- result = connector.getChangedSinceLastSync(repository, tasks);
+ result = connector.getChangedSinceLastSync(repository, tasks, new NullProgressMonitor());
assertTrue(result.isEmpty());
// change ticket making sure it gets a new change time
@@ -139,7 +139,7 @@ public class TracTaskDataHandlerTest extends TestCase {
client.updateTicket(ticket, "comment");
repository.setSyncTimeStamp((lastModified + 1) + "");
- result = connector.getChangedSinceLastSync(repository, tasks);
+ result = connector.getChangedSinceLastSync(repository, tasks, new NullProgressMonitor());
assertEquals(tasks, result);
}

Back to the top