gobuf/inject_tag_test.go
2023-06-25 23:02:26 +08:00

18 lines
319 B
Go

package gobuf
import (
"github.com/stretchr/testify/assert"
"testing"
)
func TestInjectTag_Inject(t *testing.T) {
var parser = NewInjectTag("./example.pb.go")
err := parser.WithTags(InjectTagProps{
TagName: "bson",
}, InjectTagProps{
TagName: "pson",
Style: LowerCase,
}).Inject()
assert.Nil(t, err)
}