type Weather struct{ testo.Suite[*testo.T] }
func (Weather) CasesWind() []float64 {
return []float64{2.5, 20}
}
func (Weather) CasesTemp() []float64 {
return []float64{-10, 19, 40}
}
func (Weather) CasesHumidity() []float64 {
return []float64{61, 90}
}
func (Weather) TestFeelsLike(
t *testo.T, p struct{ Temp, Humidity, Wind float64 },
) {
real := FeelsLike(p.Temp, p.Humidity, p.Wind)
t.Logf("%+v ощущается как %.1fºC", p, real)
}
func Test(t *testing.T) {
testo.RunSuite(t, new(Weather))
}