mirror of
https://github.com/ScuroNeko/mtg.git
synced 2026-09-01 10:34:02 +03:00
Add unmarshal nil test for prefer ip
This commit is contained in:
@@ -18,6 +18,12 @@ type TypePreferIPTestSuite struct {
|
|||||||
suite.Suite
|
suite.Suite
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (suite *TypePreferIPTestSuite) TestUnmarshalNil() {
|
||||||
|
typ := &config.TypePreferIP{}
|
||||||
|
suite.NoError(typ.UnmarshalText(nil))
|
||||||
|
suite.Empty(typ.String())
|
||||||
|
}
|
||||||
|
|
||||||
func (suite *TypePreferIPTestSuite) TestUnmarshalFail() {
|
func (suite *TypePreferIPTestSuite) TestUnmarshalFail() {
|
||||||
testData := []string{
|
testData := []string{
|
||||||
"p",
|
"p",
|
||||||
|
|||||||
Reference in New Issue
Block a user