mirror of
				https://github.com/taigrr/godns
				synced 2025-01-18 04:03:25 -08:00 
			
		
		
		
	add test case
This commit is contained in:
		
							parent
							
								
									d0dfa698b0
								
							
						
					
					
						commit
						732e97a294
					
				| @ -13,6 +13,11 @@ func TestLoadSetting(t *testing.T) { | |||||||
| 	} | 	} | ||||||
| 
 | 
 | ||||||
| 	if settings.IPUrl == "" { | 	if settings.IPUrl == "" { | ||||||
| 		t.Error("Cannot load ip_url from config file") | 		t.Error("cannot load ip_url from config file") | ||||||
|  | 	} | ||||||
|  | 
 | ||||||
|  | 	err = LoadSettings("./file/does/not/exists", &settings) | ||||||
|  | 	if err == nil { | ||||||
|  | 		t.Error("file doesn't exist, should return error") | ||||||
| 	} | 	} | ||||||
| } | } | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user