Update Android drawable used in Tiles golden tests.
This updates android_withbg_120dp to not depend on adaptive-icon, since
that can render differently on different device images (and hence, the
changes in aosp/1998190 break us).
Bug: 222476294
Test: It's test code ;)
Change-Id: I66a5f46793581176934c230eb3ddd5fdebbd53ad
diff --git a/wear/tiles/tiles-renderer/src/androidTest/java/androidx/wear/tiles/renderer/test/TileRendererGoldenTest.java b/wear/tiles/tiles-renderer/src/androidTest/java/androidx/wear/tiles/renderer/test/TileRendererGoldenTest.java
index e3c0260..44045e5 100644
--- a/wear/tiles/tiles-renderer/src/androidTest/java/androidx/wear/tiles/renderer/test/TileRendererGoldenTest.java
+++ b/wear/tiles/tiles-renderer/src/androidTest/java/androidx/wear/tiles/renderer/test/TileRendererGoldenTest.java
@@ -180,7 +180,7 @@
ImageResource.newBuilder()
.setAndroidResourceByResId(
AndroidImageResourceByResId.newBuilder()
- .setResourceId(R.mipmap.android_withbg_120dp))
+ .setResourceId(R.drawable.android_withbg_120dp))
.build())
.putIdToImage(
"inline",
diff --git a/wear/tiles/tiles-renderer/src/androidTest/res/drawable/ic_channel_foreground.xml b/wear/tiles/tiles-renderer/src/androidTest/res/drawable/android_withbg_120dp.xml
similarity index 69%
rename from wear/tiles/tiles-renderer/src/androidTest/res/drawable/ic_channel_foreground.xml
rename to wear/tiles/tiles-renderer/src/androidTest/res/drawable/android_withbg_120dp.xml
index 399d346..07f355d 100644
--- a/wear/tiles/tiles-renderer/src/androidTest/res/drawable/ic_channel_foreground.xml
+++ b/wear/tiles/tiles-renderer/src/androidTest/res/drawable/android_withbg_120dp.xml
@@ -2,14 +2,12 @@
android:width="120dp"
android:height="120dp"
android:viewportWidth="120"
- android:viewportHeight="120"
- android:tint="#FFFFFF">
- <group android:scaleX="2.9"
- android:scaleY="2.9"
- android:translateX="25.2"
- android:translateY="25.2">
+ android:viewportHeight="120">
+ <path android:fillColor="#FF3DDC84" android:pathData="M0,0 H120 V120 H-120 Z" />
+ <group android:scaleX="5"
+ android:scaleY="5">
<path
android:pathData="M17.6,11.48 L19.44,8.3a0.63,0.63 0,0 0,-1.09 -0.63l-1.88,3.24a11.43,11.43 0,0 0,-8.94 0L5.65,7.67a0.63,0.63 0,0 0,-1.09 0.63L6.4,11.48A10.81,10.81 0,0 0,1 20L23,20A10.81,10.81 0,0 0,17.6 11.48ZM7,17.25A1.25,1.25 0,1 1,8.25 16,1.25 1.25,0 0,1 7,17.25ZM17,17.25A1.25,1.25 0,1 1,18.25 16,1.25 1.25,0 0,1 17,17.25Z"
- android:fillColor="#FF000000"/>
+ android:fillColor="#FFFFFFFF"/>
</group>
</vector>
diff --git a/wear/tiles/tiles-renderer/src/androidTest/res/mipmap-anydpi-v26/android_withbg_120dp.xml b/wear/tiles/tiles-renderer/src/androidTest/res/mipmap-anydpi-v26/android_withbg_120dp.xml
deleted file mode 100644
index 5c4c23a..0000000
--- a/wear/tiles/tiles-renderer/src/androidTest/res/mipmap-anydpi-v26/android_withbg_120dp.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
- <background android:drawable="@color/ic_channel_background"/>
- <foreground android:drawable="@drawable/ic_channel_foreground"/>
-</adaptive-icon>
diff --git a/wear/tiles/tiles-renderer/src/androidTest/res/values/ic_channel_background.xml b/wear/tiles/tiles-renderer/src/androidTest/res/values/ic_channel_background.xml
deleted file mode 100644
index fe558ce..0000000
--- a/wear/tiles/tiles-renderer/src/androidTest/res/values/ic_channel_background.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<resources>
- <color name="ic_channel_background">#3DDC84</color>
-</resources>