File tree Expand file tree Collapse file tree 3 files changed +12
-5
lines changed
main/java/com/spotify/github/v3/prs
java/com/spotify/github/v3/activity/events
resources/com/spotify/github/v3/activity/events/fixtures Expand file tree Collapse file tree 3 files changed +12
-5
lines changed Original file line number Diff line number Diff line change 77 * Licensed under the Apache License, Version 2.0 (the "License");
88 * you may not use this file except in compliance with the License.
99 * You may obtain a copy of the License at
10- *
10+ *
1111 * http://www.apache.org/licenses/LICENSE-2.0
12- *
12+ *
1313 * Unless required by applicable law or agreed to in writing, software
1414 * distributed under the License is distributed on an "AS IS" BASIS,
1515 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -94,4 +94,8 @@ public interface Comment extends UpdateTracking {
9494 @ Nullable
9595 @ JsonProperty ("_links" )
9696 CommentLinks links ();
97+
98+ /** Node ID */
99+ @ Nullable
100+ String nodeId ();
97101}
Original file line number Diff line number Diff line change 2020
2121package com .spotify .github .v3 .activity .events ;
2222
23- import static com . google . common . io .Resources . getResource ;
23+ import java . io .IOException ;
2424import static java .nio .charset .Charset .defaultCharset ;
25+
2526import static org .hamcrest .MatcherAssert .assertThat ;
2627import static org .hamcrest .core .Is .is ;
28+ import org .junit .jupiter .api .Test ;
2729
2830import com .google .common .io .Resources ;
31+ import static com .google .common .io .Resources .getResource ;
2932import com .spotify .github .jackson .Json ;
30- import java .io .IOException ;
31- import org .junit .jupiter .api .Test ;
3233
3334public class PullRequestReviewCommentEventTest {
3435 @ Test
@@ -41,6 +42,7 @@ public void testDeserialization() throws IOException {
4142 Json .create ().fromJson (fixture , PullRequestReviewCommentEvent .class );
4243 assertThat (event .action (), is ("created" ));
4344 assertThat (event .comment ().id (), is (29724692L ));
45+ assertThat (event .comment ().nodeId (), is ("abc234" ));
4446 assertThat (event .pullRequest ().nodeId (), is ("abc123" ));
4547 assertThat (event .comment ().body (), is ("Maybe you should use more emojji on this line." ));
4648 }
Original file line number Diff line number Diff line change 33 "comment" : {
44 "url" : " https://api.github.com/repos/baxterthehacker/public-repo/pulls/comments/29724692" ,
55 "id" : 29724692 ,
6+ "node_id" : " abc234" ,
67 "diff_hunk" : " @@ -1 +1 @@\n -# public-repo" ,
78 "path" : " README.md" ,
89 "position" : 1 ,
You can’t perform that action at this time.
0 commit comments