File tree Expand file tree Collapse file tree
main/java/org/kohsuke/github
test/java/org/kohsuke/github Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -492,6 +492,16 @@ public boolean isMerged() throws IOException {
492492 return merged ;
493493 }
494494
495+ /**
496+ * Since a GHPullRequest is always a pull request, this method always returns true.
497+ *
498+ * @return true
499+ */
500+ @ Override
501+ public boolean isPullRequest () {
502+ return true ;
503+ }
504+
495505 /**
496506 * Retrieves all the commits associated to this pull request.
497507 *
Original file line number Diff line number Diff line change @@ -1081,6 +1081,7 @@ public void pull_request() throws Exception {
10811081 assertThat (event .getPullRequest ().getBase ().getLabel (), is ("baxterthehacker:main" ));
10821082 assertThat (event .getPullRequest ().getBase ().getSha (), is ("9049f1265b7d61be4a8904a9a27120d2064dab3b" ));
10831083 assertThat (event .getPullRequest ().isMerged (), is (false ));
1084+ assertThat (event .getPullRequest ().isPullRequest (), is (true ));
10841085 assertThat (event .getPullRequest ().getMergeable (), nullValue ());
10851086 assertThat (event .getPullRequest ().getMergeableState (), is ("unknown" ));
10861087 assertThat (event .getPullRequest ().getMergedBy (), nullValue ());
You can’t perform that action at this time.
0 commit comments