Update StringUtil#formatElapsedTime method (2/3)

- Update the usage and the test case
 - Update discharging string to follow new string doc

Bug: 183689347
Test: make RunSettingsRoboTests
Change-Id: I1e14e7da8cb02755d8cf6e12626a0d94fad87121
This commit is contained in:
Wesley.CW Wang
2021-04-01 18:56:57 +08:00
committed by Wesley Wang
parent acacad4cdf
commit 50f314e45d
9 changed files with 37 additions and 15 deletions

View File

@@ -473,9 +473,9 @@ public class AdvancedBluetoothDetailsHeaderControllerTest {
@Test
public void showBatteryPredictionIfNecessary_estimateReadyIsAvailable_showCorrectValue() {
final String leftBatteryPrediction =
StringUtil.formatElapsedTime(mContext, 12000000, false).toString();
StringUtil.formatElapsedTime(mContext, 12000000, false, false).toString();
final String rightBatteryPrediction =
StringUtil.formatElapsedTime(mContext, 1200000, false).toString();
StringUtil.formatElapsedTime(mContext, 1200000, false, false).toString();
mController.showBatteryPredictionIfNecessary(1, 12000000,
mLayoutPreference.findViewById(R.id.layout_left));