Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorspingel2007-02-17 13:24:34 -0500
committerspingel2007-02-17 13:24:34 -0500
commit3645f6191dce4abda8f696c4ebd4b419105cc175 (patch)
tree3c3eda02c4a6c8e5e4d6b38d5194d1ee23df4085 /org.eclipse.mylyn.trac.tests
parent63a62c7c03547258ec71bfb8d0d5ac72679476dd (diff)
downloadorg.eclipse.mylyn.tasks-3645f6191dce4abda8f696c4ebd4b419105cc175.tar.gz
org.eclipse.mylyn.tasks-3645f6191dce4abda8f696c4ebd4b419105cc175.tar.xz
org.eclipse.mylyn.tasks-3645f6191dce4abda8f696c4ebd4b419105cc175.zip
NEW - bug 174552: Trac does not check if task id is numeric
https://bugs.eclipse.org/bugs/show_bug.cgi?id=174552
Diffstat (limited to 'org.eclipse.mylyn.trac.tests')
-rw-r--r--org.eclipse.mylyn.trac.tests/src/org/eclipse/mylyn/trac/tests/AllTracTests.java2
-rw-r--r--org.eclipse.mylyn.trac.tests/src/org/eclipse/mylyn/trac/tests/TracTaskDataHandlerTest.java (renamed from org.eclipse.mylyn.trac.tests/src/org/eclipse/mylyn/trac/tests/TracOfflineTaskHandlerTest.java)14
2 files changed, 13 insertions, 3 deletions
diff --git a/org.eclipse.mylyn.trac.tests/src/org/eclipse/mylyn/trac/tests/AllTracTests.java b/org.eclipse.mylyn.trac.tests/src/org/eclipse/mylyn/trac/tests/AllTracTests.java
index 567f288f7..740761ac6 100644
--- a/org.eclipse.mylyn.trac.tests/src/org/eclipse/mylyn/trac/tests/AllTracTests.java
+++ b/org.eclipse.mylyn.trac.tests/src/org/eclipse/mylyn/trac/tests/AllTracTests.java
@@ -39,7 +39,7 @@ public class AllTracTests {
suite.addTestSuite(TracClientManagerTest.class);
suite.addTestSuite(TracAttachmentHandlerTest.class);
suite.addTestSuite(RepositorySearchQueryTest.class);
- suite.addTestSuite(TracOfflineTaskHandlerTest.class);
+ suite.addTestSuite(TracTaskDataHandlerTest.class);
suite.addTestSuite(TracTaskTest.class);
suite.addTestSuite(TracQueryHitTest.class);
suite.addTestSuite(TracRepositorySettingsPageTest.class);
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/TracTaskDataHandlerTest.java
index 157050b10..783d8f989 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/TracTaskDataHandlerTest.java
@@ -16,6 +16,7 @@ import java.util.Set;
import junit.framework.TestCase;
+import org.eclipse.core.runtime.CoreException;
import org.eclipse.mylar.context.tests.support.MylarTestUtils;
import org.eclipse.mylar.context.tests.support.MylarTestUtils.Credentials;
import org.eclipse.mylar.context.tests.support.MylarTestUtils.PrivilegeLevel;
@@ -36,7 +37,7 @@ import org.eclipse.mylar.trac.tests.support.XmlRpcServer.TestData;
/**
* @author Steffen Pingel
*/
-public class TracOfflineTaskHandlerTest extends TestCase {
+public class TracTaskDataHandlerTest extends TestCase {
private TracRepositoryConnector connector;
@@ -46,7 +47,7 @@ public class TracOfflineTaskHandlerTest extends TestCase {
private TestData data;
- public TracOfflineTaskHandlerTest() {
+ public TracTaskDataHandlerTest() {
}
@Override
@@ -128,5 +129,14 @@ public class TracOfflineTaskHandlerTest extends TestCase {
result = connector.getChangedSinceLastSync(repository, tasks);
assertEquals(tasks, result);
}
+
+ public void testNonNumericTaskId() {
+ try {
+ connector.getTaskDataHandler().getTaskData(repository, "abc");
+ fail("Expected CoreException");
+ } catch (CoreException e) {
+ }
+ }
+
}

Back to the top