Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLeo Ufimtsev2016-09-22 18:48:58 +0000
committerGerrit Code Review @ Eclipse.org2016-10-06 19:04:48 +0000
commit2abd17c2ef00212b7ebd680d0c866ced9195d167 (patch)
tree06e073ca34ef3ac80958dc38f5965d53497135b2 /org.eclipse.mylyn.tasks.tests
parente73deec9f6c8974fcb6c787067bc7be9b8fd1b30 (diff)
downloadorg.eclipse.mylyn.tasks-2abd17c2ef00212b7ebd680d0c866ced9195d167.tar.gz
org.eclipse.mylyn.tasks-2abd17c2ef00212b7ebd680d0c866ced9195d167.tar.xz
org.eclipse.mylyn.tasks-2abd17c2ef00212b7ebd680d0c866ced9195d167.zip
Bug 501868: In "copy details" please add "ID and Summary"
- Added "ID and Summary" field. - Following bugzilla convention, I capitalized "Bug" (from "bug") - NOTE: 'SUMMARY' was already in the code base, but it was not used, maybe left overs from the past... I basically recycled and re-used SUMMARY. Patch set 3: - Removed the task ID and Summary seperattor introduced in patchset 1. - Refactored/Renamed a bunch of variables. - Removed comment out line in ID_SUMMARY_URL - Refactored Mode enum to remove switch statement. Patch set 4: - Renamed "Bug" back to "bug" in BugzillaRepositoryConnector - In CopyTaskDetailsAction, capitalized prefix as per suggestion. Patch set 5: - Updated test cases to use renamed enum. Change-Id: I1441c0e4fc975eba225ac79077ff65a26074cc13 Task-Url: https://bugs.eclipse.org/bugs/show_bug.cgi?id=501868 Signed-off-by: Leo Ufimtsev <lufimtse@redhat.com>
Diffstat (limited to 'org.eclipse.mylyn.tasks.tests')
-rw-r--r--org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/CopyDetailsActionTest.java20
1 files changed, 10 insertions, 10 deletions
diff --git a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/CopyDetailsActionTest.java b/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/CopyDetailsActionTest.java
index 840b8e3c6..e6e44c4c2 100644
--- a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/CopyDetailsActionTest.java
+++ b/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/CopyDetailsActionTest.java
@@ -14,8 +14,6 @@ package org.eclipse.mylyn.tasks.tests;
import java.net.MalformedURLException;
import java.net.URL;
-import junit.framework.TestCase;
-
import org.eclipse.mylyn.commons.ui.ClipboardCopier;
import org.eclipse.mylyn.internal.tasks.core.TaskRepositoryManager;
import org.eclipse.mylyn.internal.tasks.ui.actions.CopyTaskDetailsAction;
@@ -27,6 +25,8 @@ import org.eclipse.mylyn.tasks.tests.connector.MockRepositoryConnector;
import org.eclipse.mylyn.tasks.tests.connector.MockTask;
import org.eclipse.mylyn.tasks.ui.TasksUi;
+import junit.framework.TestCase;
+
/**
* @author Steffen Pingel
* @author Thomas Ehrnhoefer
@@ -81,12 +81,12 @@ public class CopyDetailsActionTest extends TestCase {
return "http://321.com";
}
};
- AbstractRepositoryConnector oldConnector = TasksUi.getRepositoryManager().getRepositoryConnector(
- MockRepositoryConnector.CONNECTOR_KIND);
+ AbstractRepositoryConnector oldConnector = TasksUi.getRepositoryManager()
+ .getRepositoryConnector(MockRepositoryConnector.CONNECTOR_KIND);
try {
((TaskRepositoryManager) TasksUi.getRepositoryManager()).addRepositoryConnector(connector);
assertEquals("321: s321" + ClipboardCopier.LINE_SEPARATOR + "http://321.com",
- CopyTaskDetailsAction.getTextForTask(task, Mode.SUMMARY_URL));
+ CopyTaskDetailsAction.getTextForTask(task, Mode.ID_SUMMARY_URL));
} finally {
if (oldConnector != null) {
((TaskRepositoryManager) TasksUi.getRepositoryManager()).addRepositoryConnector(oldConnector);
@@ -115,13 +115,13 @@ public class CopyDetailsActionTest extends TestCase {
};
- AbstractRepositoryConnector oldConnector = TasksUi.getRepositoryManager().getRepositoryConnector(
- MockRepositoryConnector.CONNECTOR_KIND);
+ AbstractRepositoryConnector oldConnector = TasksUi.getRepositoryManager()
+ .getRepositoryConnector(MockRepositoryConnector.CONNECTOR_KIND);
try {
((TaskRepositoryManager) TasksUi.getRepositoryManager()).addRepositoryConnector(connector);
- assertEquals("123: Ticket 123" + ClipboardCopier.LINE_SEPARATOR
- + "http://mock-repo-evolved.com/tickets/123",
- CopyTaskDetailsAction.getTextForTask(task, Mode.SUMMARY_URL));
+ assertEquals(
+ "123: Ticket 123" + ClipboardCopier.LINE_SEPARATOR + "http://mock-repo-evolved.com/tickets/123",
+ CopyTaskDetailsAction.getTextForTask(task, Mode.ID_SUMMARY_URL));
assertEquals("http://mock-repo-evolved.com/tickets/123",
CopyTaskDetailsAction.getTextForTask(task, Mode.URL));
} finally {

Back to the top