1
0
mirror of https://github.com/taigrr/godns synced 2025-01-18 04:03:25 -08:00

add test case

This commit is contained in:
Timothy 2017-10-27 14:47:36 +08:00
parent 377d91d969
commit d0dfa698b0

View File

@ -35,6 +35,11 @@ func TestCheckSettings(t *testing.T) {
t.Error("setting with login token, should be passed")
}
settingDNSPod = &Settings{Provider: "DNSPod"}
if err := CheckSettings(settingDNSPod); err == nil {
t.Error("setting with invalid parameters, should be failed")
}
settingHE := &Settings{Provider: "HE", Password: ""}
if err := CheckSettings(settingHE); err != nil {
t.Log("HE setting without password, passed")