Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRaquel Pau2018-02-21 18:38:39 +0000
committerRaquel Pau2018-02-21 18:59:07 +0000
commit900e69e2e8fd81d851e62f86587c86f255a0b273 (patch)
tree2ab05d309879f5646a7afd67e9d0e5c9858c664b /org.eclipse.egit.github.core.tests/src/org/eclipse/egit/github
parent8b24d5046e5f2813d8df5f1b4a13ed8f323aea23 (diff)
downloadegit-github-900e69e2e8fd81d851e62f86587c86f255a0b273.tar.gz
egit-github-900e69e2e8fd81d851e62f86587c86f255a0b273.tar.xz
egit-github-900e69e2e8fd81d851e62f86587c86f255a0b273.zip
Add the assignees list in pull request
A pull request can be assigned to a list of people. The pull request object returned by the pull request payload contains that list. This patch adds the "assignees" field into the pull request object. This is an example: https://gist.github.com/rpau/3a68abf2e0af60e1e8b155e9b6d5e5a1 Change-Id: Ib28d4d8ae0ee71a60fc6381d131f669a6d4d788f Signed-off-by: Raquel Pau <raquel.pau@schibsted.com>
Diffstat (limited to 'org.eclipse.egit.github.core.tests/src/org/eclipse/egit/github')
-rwxr-xr-xorg.eclipse.egit.github.core.tests/src/org/eclipse/egit/github/core/tests/PullRequestTest.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/org.eclipse.egit.github.core.tests/src/org/eclipse/egit/github/core/tests/PullRequestTest.java b/org.eclipse.egit.github.core.tests/src/org/eclipse/egit/github/core/tests/PullRequestTest.java
index 90a2553f..57450280 100755
--- a/org.eclipse.egit.github.core.tests/src/org/eclipse/egit/github/core/tests/PullRequestTest.java
+++ b/org.eclipse.egit.github.core.tests/src/org/eclipse/egit/github/core/tests/PullRequestTest.java
@@ -16,7 +16,9 @@ import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertNull;
import static org.junit.Assert.assertTrue;
+import java.util.Arrays;
import java.util.Date;
+import java.util.List;
import org.eclipse.egit.github.core.Milestone;
import org.eclipse.egit.github.core.PullRequest;
@@ -66,6 +68,7 @@ public class PullRequestTest {
assertEquals(0, request.getId());
assertNull(request.getMilestone());
assertNull(request.getAssignee());
+ assertNull(request.getAssignees());
}
/**
@@ -117,6 +120,9 @@ public class PullRequestTest {
assertEquals(assignee, request.setAssignee(assignee).getAssignee());
Milestone milestone = new Milestone().setNumber(456);
assertEquals(milestone, request.setMilestone(milestone).getMilestone());
+
+ List<User> assigneeList = Arrays.asList(assignee);
+ assertEquals(assigneeList, request.setAssignees(Arrays.asList(assignee)).getAssignees());
}
/**

Back to the top