[bug] Fix crash on generating enum sql builder files when enum contains numeric values.
This commit is contained in:
parent
f154701e60
commit
63c1fd6430
5 changed files with 42 additions and 5 deletions
|
|
@ -25,6 +25,11 @@ func TestToGoIdentifier(t *testing.T) {
|
|||
assert.Equal(t, ToGoIdentifier("My-Table"), "MyTable")
|
||||
}
|
||||
|
||||
func TestToGoEnumValueIdentifier(t *testing.T) {
|
||||
assert.Equal(t, ToGoEnumValueIdentifier("enum_name", "enum_value"), "EnumValue")
|
||||
assert.Equal(t, ToGoEnumValueIdentifier("NumEnum", "100"), "NumEnum100")
|
||||
}
|
||||
|
||||
func TestErrorCatchErr(t *testing.T) {
|
||||
var err error
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue