Skip to content

Commit

Permalink
Added display_title parameter for workspace run
Browse files Browse the repository at this point in the history
  • Loading branch information
Elena committed May 23, 2023
1 parent 5380f59 commit c1b747f
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/main/java/org/kohsuke/github/GHWorkflowRun.java
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ public class GHWorkflowRun extends GHObject {
private GHRepository owner;

private String name;
private String displayTitle;
private long runNumber;
private long workflowId;

Expand Down Expand Up @@ -65,6 +66,15 @@ public String getName() {
return name;
}

/**
* The display title of the workflow run.
*
* @return the displayTitle
*/
public String getDisplayTitle() {
return displayTitle;
}

/**
* The run number.
*
Expand Down
1 change: 1 addition & 0 deletions src/test/java/org/kohsuke/github/GHEventPayloadTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -1062,6 +1062,7 @@ public void workflow_run() throws Exception {
assertThat(workflowRun.getId(), is(680604745L));
assertThat(workflowRun.getName(), is("CI"));
assertThat(workflowRun.getHeadBranch(), is("main"));
assertThat(workflowRun.getDisplayTitle(), is("its-display-title"));
assertThat(workflowRun.getHeadSha(), is("dbea8d8b6ed2cf764dfd84a215f3f9040b3d4423"));
assertThat(workflowRun.getRunNumber(), is(6L));
assertThat(workflowRun.getEvent(), is(GHEvent.WORKFLOW_DISPATCH));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
"node_id": "MDExOldvcmtmbG93UnVuNjgwNjA0NzQ1",
"head_branch": "main",
"head_sha": "dbea8d8b6ed2cf764dfd84a215f3f9040b3d4423",
"display_title": "its-display-title",
"run_number": 6,
"event": "workflow_dispatch",
"status": "completed",
Expand Down

0 comments on commit c1b747f

Please sign in to comment.