Implement default precision=0 for upstream weatherapi endpoints
This commit is contained in:
@@ -28,6 +28,9 @@ func TestDefaults(t *testing.T) {
|
||||
if cfg.WeatherAPI.Format != "json" {
|
||||
t.Fatalf("Format = %q, want json", cfg.WeatherAPI.Format)
|
||||
}
|
||||
if cfg.WeatherAPI.Precision != 0 {
|
||||
t.Fatalf("Precision = %d, want 0", cfg.WeatherAPI.Precision)
|
||||
}
|
||||
if cfg.Location.ID != "home" || cfg.Location.Name != "Brentwood" || cfg.Location.Region != "St. Louis Metro" {
|
||||
t.Fatalf("Location = %#v, want home/Brentwood/St. Louis Metro", cfg.Location)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user