Skip to content

Commit

Permalink
refactor error message log
Browse files Browse the repository at this point in the history
  • Loading branch information
bote795 committed Jun 21, 2021
1 parent 12c3027 commit 9decaec
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion cmd/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ func prepareDefaultAirflowImageTag(airflowVersion string, httpClient *airflowver
defaultImageTag = fmt.Sprintf("%s-buster-onbuild", airflowVersion)
}
} else if airflowVersion != "" {
return "", errors.New("you can't use --airflow-version option while not authenticated to a cluster")
return "", errors.New("An Error occurred: Are you authenticated? If not - you can't use the --airflow-version option")
}

if len(defaultImageTag) == 0 {
Expand Down
2 changes: 1 addition & 1 deletion cmd/utils_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,6 @@ func Test_prepareDefaultAirflowImageTagHoustonBadRequest(t *testing.T) {
output := new(bytes.Buffer)

defaultTag, err := prepareDefaultAirflowImageTag("2.0.2", httpClient, api, output)
assert.Error(t, err, "you can't use --airflow-version option while not authenticated to a cluster")
assert.Error(t, err, "An Error occurred: Are you authenticated? If not - you can't use the --airflow-version option")
assert.Equal(t, "", defaultTag)
}

0 comments on commit 9decaec

Please sign in to comment.