Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJon Ander Peñalba2015-03-12 13:34:14 -0400
committerMatthias Sohn2015-03-12 16:53:36 -0400
commit975e702acabd43c6e2a890a69a7d7f0605c09afb (patch)
treedefa96cc53012e7a020aa14e6ba8e08cf8caa1c2
parentd1d5d162eff483a234c1f9706fd31468f5c9f98b (diff)
downloadegit-github-975e702acabd43c6e2a890a69a7d7f0605c09afb.tar.gz
egit-github-975e702acabd43c6e2a890a69a7d7f0605c09afb.tar.xz
egit-github-975e702acabd43c6e2a890a69a7d7f0605c09afb.zip
Added `closedBy` field to the Issue class
Change-Id: I636211c9996303697614c8a3bfd69ffaca58b190 Signed-off-by: Jon Ander Peñalba <jonan88@gmail.com> Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
-rw-r--r--org.eclipse.egit.github.core.tests/src/org/eclipse/egit/github/core/tests/IssueTest.java2
-rw-r--r--org.eclipse.egit.github.core/src/org/eclipse/egit/github/core/Issue.java18
2 files changed, 20 insertions, 0 deletions
diff --git a/org.eclipse.egit.github.core.tests/src/org/eclipse/egit/github/core/tests/IssueTest.java b/org.eclipse.egit.github.core.tests/src/org/eclipse/egit/github/core/tests/IssueTest.java
index 58b31d62..56cf3015 100644
--- a/org.eclipse.egit.github.core.tests/src/org/eclipse/egit/github/core/tests/IssueTest.java
+++ b/org.eclipse.egit.github.core.tests/src/org/eclipse/egit/github/core/tests/IssueTest.java
@@ -55,6 +55,7 @@ public class IssueTest {
assertNull(issue.getUser());
assertNotNull(issue.toString());
assertEquals(0, issue.getId());
+ assertNull(issue.getClosedBy());
}
/**
@@ -90,6 +91,7 @@ public class IssueTest {
assertEquals(user, issue.setUser(user).getUser());
assertNull(issue.setLabels(null).getLabels());
assertEquals(39, issue.setId(39).getId());
+ assertEquals("user", issue.setClosedBy(user).getClosedBy().getLogin());
}
/**
diff --git a/org.eclipse.egit.github.core/src/org/eclipse/egit/github/core/Issue.java b/org.eclipse.egit.github.core/src/org/eclipse/egit/github/core/Issue.java
index e927642a..dd88044e 100644
--- a/org.eclipse.egit.github.core/src/org/eclipse/egit/github/core/Issue.java
+++ b/org.eclipse.egit.github.core/src/org/eclipse/egit/github/core/Issue.java
@@ -61,6 +61,8 @@ public class Issue implements Serializable {
private User user;
+ private User closedBy;
+
/**
* @return closedAt
*/
@@ -334,6 +336,22 @@ public class Issue implements Serializable {
}
/**
+ * @return closedBy
+ */
+ public User getClosedBy() {
+ return closedBy;
+ }
+
+ /**
+ * @param closedBy
+ * @return this issue
+ */
+ public Issue setClosedBy(User closedBy) {
+ this.closedBy = closedBy;
+ return this;
+ }
+
+ /**
* @return id
*/
public long getId() {

Back to the top