Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSam Davis2013-01-14 19:37:48 -0500
committerSam Davis2014-02-18 17:38:57 -0500
commitda88421f3737f215c9e7e247f6847f69ed363d09 (patch)
treedf2a85ad99618b29fdf528c5d1afd04894eebc33 /org.eclipse.mylyn.bugzilla.tests
parent2e728e5d380a13ab769830d588ebff70a60f19b9 (diff)
downloadorg.eclipse.mylyn.tasks-da88421f3737f215c9e7e247f6847f69ed363d09.tar.gz
org.eclipse.mylyn.tasks-da88421f3737f215c9e7e247f6847f69ed363d09.tar.xz
org.eclipse.mylyn.tasks-da88421f3737f215c9e7e247f6847f69ed363d09.zip
278474: store TaskRepository credentials in SecureCredentialsStore
Change-Id: I93daacac2280c009b98d02395d4a5989f5c0a16a Task-Url: https://bugs.eclipse.org/bugs/show_bug.cgi?id=278474
Diffstat (limited to 'org.eclipse.mylyn.bugzilla.tests')
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/BugzillaAttachmentHandlerTest.java2
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/BugzillaRepositoryConnectorTest.java2
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/RepositoryReportFactoryTest.java2
3 files changed, 6 insertions, 0 deletions
diff --git a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/BugzillaAttachmentHandlerTest.java b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/BugzillaAttachmentHandlerTest.java
index 11ed986fc..3f278c6da 100644
--- a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/BugzillaAttachmentHandlerTest.java
+++ b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/BugzillaAttachmentHandlerTest.java
@@ -480,6 +480,8 @@ public class BugzillaAttachmentHandlerTest extends AbstractBugzillaTest {
}
public void testContextAttachFailure() throws Exception {
+ // use the client's repository when setting credentials below
+ repository = client.getTaskRepository();
TaskData taskData = BugzillaFixture.current().createTask(PrivilegeLevel.USER, null, null);
assertNotNull(taskData);
ITask task = TasksUi.getRepositoryModel().createTask(repository, taskData.getTaskId());
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 9d1b36208..070db104f 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
@@ -938,6 +938,8 @@ public class BugzillaRepositoryConnectorTest extends AbstractBugzillaTest {
}
public void testAuthenticationCredentials() throws Exception {
+ // use the client's repository when setting credentials below
+ repository = client.getTaskRepository();
TaskData data = BugzillaFixture.current().createTask(PrivilegeLevel.USER, null, null);
assertNotNull(data);
ITask task = generateLocalTaskAndDownload(data.getTaskId());
diff --git a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/RepositoryReportFactoryTest.java b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/RepositoryReportFactoryTest.java
index c66c4142b..e399b399b 100644
--- a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/RepositoryReportFactoryTest.java
+++ b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/RepositoryReportFactoryTest.java
@@ -52,6 +52,8 @@ public class RepositoryReportFactoryTest extends TestCase {
public void testInvalidCredentials() throws Exception {
try {
client.logout(new NullProgressMonitor());
+ // use the client's repository when setting credentials below
+ repository = client.getTaskRepository();
repository.setCredentials(AuthenticationType.REPOSITORY,
new AuthenticationCredentials("invalid", "invalid"), false);
connector.getTaskData(repository, "1", new NullProgressMonitor());

Back to the top