Merge "Switch to using gray icon for Bluetooth imaging devices" into oc-dr1-dev

am: a6ac4890ed

Change-Id: Ib4cbffa94b0372419f60f16972836df27ad1fecf
This commit is contained in:
Antony Sargent
2017-07-22 00:32:00 +00:00
committed by android-build-merger
3 changed files with 11 additions and 28 deletions

View File

@@ -15,6 +15,7 @@
*/
package com.android.settings.bluetooth;
import android.bluetooth.BluetoothClass;
import android.bluetooth.BluetoothDevice;
import android.content.Context;
import android.os.UserManager;
@@ -136,4 +137,13 @@ public class BluetoothDevicePreferenceTest {
assertThat(mPreference.shouldHideSecondTarget()).isFalse();
}
@Test
public void imagingDeviceIcon_isICSettingsPrint() {
when(mCachedBluetoothDevice.getBtClass()).thenReturn(
new BluetoothClass(BluetoothClass.Device.Major.IMAGING));
mPreference.onDeviceAttributesChanged();
assertThat(mPreference.getIcon()).isEqualTo(
mContext.getDrawable(R.drawable.ic_settings_print));
}
}