Merge "Fix dup preference key on Connected devices page" into main
This commit is contained in:
@@ -275,7 +275,7 @@ public class BluetoothDeviceUpdaterTest {
|
||||
}
|
||||
|
||||
@Override
|
||||
protected String getPreferenceKey() {
|
||||
protected String getPreferenceKeyPrefix() {
|
||||
return "test_bt";
|
||||
}
|
||||
}
|
||||
|
@@ -16,6 +16,8 @@
|
||||
|
||||
package com.android.settings.connecteddevice.audiosharing;
|
||||
|
||||
import static com.android.settings.connecteddevice.audiosharing.AudioSharingBluetoothDeviceUpdater.PREF_KEY_PREFIX;
|
||||
|
||||
import static com.google.common.truth.Truth.assertThat;
|
||||
|
||||
import static org.mockito.ArgumentMatchers.any;
|
||||
@@ -85,7 +87,6 @@ import java.util.List;
|
||||
public class AudioSharingBluetoothDeviceUpdaterTest {
|
||||
private static final String MAC_ADDRESS = "04:52:C7:0B:D8:3C";
|
||||
private static final String TEST_DEVICE_NAME = "test";
|
||||
private static final String PREF_KEY = "audio_sharing_bt";
|
||||
private static final String TAG = "AudioSharingBluetoothDeviceUpdater";
|
||||
|
||||
@Rule public final MockitoRule mMockitoRule = MockitoJUnit.rule();
|
||||
@@ -263,7 +264,7 @@ public class AudioSharingBluetoothDeviceUpdaterTest {
|
||||
|
||||
@Test
|
||||
public void getPreferenceKey_returnsCorrectKey() {
|
||||
assertThat(mDeviceUpdater.getPreferenceKey()).isEqualTo(PREF_KEY);
|
||||
assertThat(mDeviceUpdater.getPreferenceKeyPrefix()).isEqualTo(PREF_KEY_PREFIX);
|
||||
}
|
||||
|
||||
@Test
|
||||
|
@@ -16,6 +16,8 @@
|
||||
|
||||
package com.android.settings.connecteddevice.audiosharing;
|
||||
|
||||
import static com.android.settings.connecteddevice.audiosharing.AudioSharingDeviceVolumeControlUpdater.PREF_KEY_PREFIX;
|
||||
|
||||
import static com.google.common.truth.Truth.assertThat;
|
||||
|
||||
import static org.mockito.ArgumentMatchers.any;
|
||||
@@ -79,7 +81,6 @@ import java.util.List;
|
||||
public class AudioSharingDeviceVolumeControlUpdaterTest {
|
||||
private static final String TEST_DEVICE_NAME = "test";
|
||||
private static final String TAG = "AudioSharingDeviceVolumeControlUpdater";
|
||||
private static final String PREF_KEY = "audio_sharing_volume_control";
|
||||
private static final String TEST_SETTINGS_KEY =
|
||||
"bluetooth_le_broadcast_fallback_active_group_id";
|
||||
private static final int TEST_DEVICE_GROUP_ID = 1;
|
||||
@@ -326,7 +327,7 @@ public class AudioSharingDeviceVolumeControlUpdaterTest {
|
||||
|
||||
@Test
|
||||
public void getPreferenceKey_returnsCorrectKey() {
|
||||
assertThat(mDeviceUpdater.getPreferenceKey()).isEqualTo(PREF_KEY);
|
||||
assertThat(mDeviceUpdater.getPreferenceKeyPrefix()).isEqualTo(PREF_KEY_PREFIX);
|
||||
}
|
||||
|
||||
@Test
|
||||
|
Reference in New Issue
Block a user