update
This commit is contained in:
@@ -1,25 +0,0 @@
|
||||
package myconf
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestConf(t *testing.T) {
|
||||
type Config struct {
|
||||
App struct {
|
||||
Name string
|
||||
Addr string
|
||||
Port int
|
||||
}
|
||||
|
||||
Redis struct {
|
||||
Addr string
|
||||
Db int
|
||||
}
|
||||
}
|
||||
|
||||
var config = &Config{}
|
||||
Init("test.yaml", config)
|
||||
fmt.Printf("%+v\n", config)
|
||||
}
|
||||
Reference in New Issue
Block a user