Skip to content

Commit

Permalink
github-pr-check: always fill check run name
Browse files Browse the repository at this point in the history
  • Loading branch information
haya14busa committed Sep 29, 2019
1 parent 221fb2e commit 35f495b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions doghouse/server/doghouse.go
Expand Up @@ -110,6 +110,7 @@ func (ch *Checker) createCheck(ctx context.Context) (*github.CheckRun, error) {

func (ch *Checker) postAnnotations(ctx context.Context, checkID int64, annotations []*github.CheckRunAnnotation) error {
opt := github.UpdateCheckRunOptions{
Name: ch.checkName(),
Output: &github.CheckRunOutput{
Title: github.String(ch.checkTitle()),
Summary: github.String(""), // Post summary with the last reqeust.
Expand Down
3 changes: 3 additions & 0 deletions doghouse/server/doghouse_test.go
Expand Up @@ -103,6 +103,9 @@ func TestCheck_OK(t *testing.T) {
if checkID != wantCheckID {
t.Errorf("UpdateCheckRun: checkID = %d, want %d", checkID, wantCheckID)
}
if opt.Name != name {
t.Errorf("UpdateCheckRunOptions.Name = %q, want %q", opt.Name, name)
}
annotations := opt.Output.Annotations
if len(annotations) == 0 {
if *opt.Conclusion != conclusion {
Expand Down

0 comments on commit 35f495b

Please sign in to comment.