test: add test for build pacakge info

上级 54442214
package support
import (
"reflect"
"testing"
)
func TestBuildMethodPackageInfo(t *testing.T) {
tests := []struct {
name string
want *PackageClassInfo
}{
{
"com.phodal.Coca.hello",
&PackageClassInfo{"com.phodal", "Coca", "hello"},
},
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
if got := BuildMethodPackageInfo(tt.name); !reflect.DeepEqual(got, tt.want) {
t.Errorf("BuildMethodPackageInfo() = %v, want %v", got, tt.want)
}
})
}
}
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册