slimming/config_test.go
2022-08-26 16:53:05 +08:00

29 lines
331 B
Go

package main
import (
"log"
"os"
"testing"
"gopkg.in/yaml.v3"
)
func TestConfig(t *testing.T) {
cnf := &Config{}
f, err := os.Open("config.yaml")
if err != nil {
log.Panic(err)
}
dec := yaml.NewDecoder(f)
err = dec.Decode(cnf)
if err != nil {
log.Panic(err)
}
t.Error(cnf)
}
func TestCase1(t *testing.T) {
}