CallFormatter { public String formattedCallDuration(int duration) { return String.format(Locale.ENGLISH, "%02d:%02d:%02d", duration / 3600, duration % 3600 / 60, duration % 3600 % 60); } CallFormatter(Resources resources); String format(int callType, String number, int duration); String formatForCalendar(int callType, String number, int duration); String formattedCallDuration(int duration); String callTypeString(int callType, String name);  }
@Test public void shouldFormatCallDuration() throws Exception { assertThat(formatter.formattedCallDuration(1242)).isEqualTo("00:20:42"); }