Skip to content
This repository has been archived by the owner on Feb 5, 2024. It is now read-only.

Commit

Permalink
Merge pull request #4 from shuheiktgw/add_name_to_builds_option
Browse files Browse the repository at this point in the history
Add BranchName option to BuildsByRepositoryOption
  • Loading branch information
shuheiktgw authored Nov 1, 2018
2 parents 5e9d620 + 11e02fa commit 99e89e9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions builds.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,8 @@ type BuildsOption struct {

// BuildsByRepositoryOption specifies the optional parameters for builds endpoint
type BuildsByRepositoryOption struct {
// Filters builds by name of the git branch
BranchName string `url:"branch.name,omitempty"`
// The User or Organization that created the build
CreatedBy []string `url:"created_by,omitempty,brackets"`
// Event that triggered the build
Expand Down
1 change: 1 addition & 0 deletions builds_integration_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ func TestBuildsService_Integration_ListByRepoId(t *testing.T) {
{PreviousState: []string{BuildStatePassed}},
{EventType: []string{BuildEventTypePush}},
{CreatedBy: []string{"shuheiktgwtest"}},
{BranchName: "master"},
}

for i, opt := range cases {
Expand Down

0 comments on commit 99e89e9

Please sign in to comment.