Skip to content

Commit

Permalink
Merge pull request #350 from IBM-Cloud/dev
Browse files Browse the repository at this point in the history
Release 1.0.1
  • Loading branch information
Aerex authored Oct 31, 2022
2 parents 93c7dd7 + 30cba53 commit d415846
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 9 deletions.
2 changes: 1 addition & 1 deletion bluemix/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package bluemix
import "fmt"

// Version is the SDK version
var Version = VersionType{Major: 1, Minor: 0, Build: 0}
var Version = VersionType{Major: 1, Minor: 0, Build: 1}

// VersionType describe version info
type VersionType struct {
Expand Down
11 changes: 5 additions & 6 deletions i18n/i18n.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,9 @@ const (
)

var (
bundle *i18n.Bundle
T TranslateFunc
RESOURCE_PATH = filepath.Join("i18n", "resources")
TRANSLATION_NOT_FOUND = "!!i18N_MESSAGE_NOT_FOUND!!"
bundle *i18n.Bundle
T TranslateFunc
RESOURCE_PATH = filepath.Join("i18n", "resources")
)

func init() {
Expand Down Expand Up @@ -83,9 +82,9 @@ func Translate(loc *i18n.Localizer) TranslateFunc {

// If no message is returned we can assume that that
// the translation could not be found in any of the files
// Set the message as !!i18N_MESSAGE_NOT_FOUND!!
// Set the message as the messageID
if msg == "" {
msg = TRANSLATION_NOT_FOUND
msg = messageId
}
return msg

Expand Down
3 changes: 1 addition & 2 deletions plugin_examples/list_plugin/commands/list_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package commands_test

import (
sdkmodels "github.com/IBM-Cloud/ibm-cloud-cli-sdk/bluemix/models"
"github.com/IBM-Cloud/ibm-cloud-cli-sdk/i18n"
"github.com/IBM-Cloud/ibm-cloud-cli-sdk/plugin/pluginfakes"
"github.com/IBM-Cloud/ibm-cloud-cli-sdk/plugin_examples/list_plugin/api/fakes"
. "github.com/IBM-Cloud/ibm-cloud-cli-sdk/plugin_examples/list_plugin/commands"
Expand Down Expand Up @@ -46,7 +45,7 @@ var _ = Describe("ListCommand", func() {
It("Should fail", func() {
err = cmd.Run([]string{})
Expect(err).To(HaveOccurred())
Expect(err.Error()).To(Equal(i18n.TRANSLATION_NOT_FOUND))
Expect(err.Error()).To(Equal("No CF API endpoint set. Use '{{.Command}}' to target a CloudFoundry environment."))
})
})
})
Expand Down

0 comments on commit d415846

Please sign in to comment.