Loading internal/commands/create_test.go +6 −1 Original line number Diff line number Diff line Loading @@ -42,13 +42,18 @@ func TestCreate(t *testing.T) { } func TestCreateFromFile(t *testing.T) { // Ref matches the value from file unless CI_COMMIT_SHA specified sha := os.Getenv("CI_COMMIT_SHA") if sha == "" { sha = "abcdefgh12345678" } releasedAt, _ := time.Parse(time.RFC3339, "2019-01-03T01:55:18.203Z") expectedRelease := gitlab.CreateReleaseRequest{ Name: "Release for test", Description: "This is a release for testing only.", TagName: "v1.2.3", ReleasedAt: &releasedAt, Ref: "abcdefgh12345678", Ref: sha, Assets: &gitlab.Assets{ Links: []*gitlab.Link{ { Loading internal/testdata/release.yml +1 −0 Original line number Diff line number Diff line Loading @@ -3,6 +3,7 @@ name: Release for test description: This is a release for testing only. tag-name: v1.2.3 released-at: 2019-01-03T01:55:18.203Z # The ref given here is used unless CI_COMMIT_SHA is specified ref: abcdefgh12345678 milestone: - 'v2.0' Loading Loading
internal/commands/create_test.go +6 −1 Original line number Diff line number Diff line Loading @@ -42,13 +42,18 @@ func TestCreate(t *testing.T) { } func TestCreateFromFile(t *testing.T) { // Ref matches the value from file unless CI_COMMIT_SHA specified sha := os.Getenv("CI_COMMIT_SHA") if sha == "" { sha = "abcdefgh12345678" } releasedAt, _ := time.Parse(time.RFC3339, "2019-01-03T01:55:18.203Z") expectedRelease := gitlab.CreateReleaseRequest{ Name: "Release for test", Description: "This is a release for testing only.", TagName: "v1.2.3", ReleasedAt: &releasedAt, Ref: "abcdefgh12345678", Ref: sha, Assets: &gitlab.Assets{ Links: []*gitlab.Link{ { Loading
internal/testdata/release.yml +1 −0 Original line number Diff line number Diff line Loading @@ -3,6 +3,7 @@ name: Release for test description: This is a release for testing only. tag-name: v1.2.3 released-at: 2019-01-03T01:55:18.203Z # The ref given here is used unless CI_COMMIT_SHA is specified ref: abcdefgh12345678 milestone: - 'v2.0' Loading