- Updated test names to reflect what it is testing

This commit is contained in:
vatsalgosar
2019-10-30 00:07:04 +05:30
parent db85c8f275
commit 7e61f39222
20476 changed files with 1641624 additions and 0 deletions
@@ -0,0 +1,19 @@
package com.baeldung.weather;
import java.text.MessageFormat;
class CityAndDayLength {
private final String city;
private final double dayLengthInHours;
CityAndDayLength(String city, long dayLengthInSeconds) {
this.city = city;
this.dayLengthInHours = dayLengthInSeconds / (60.0 * 60.0);
}
@Override
public String toString() {
return MessageFormat.format("In {0} there are {1,number,#0.0} hours of light.", city, dayLengthInHours);
}
}