summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJane Ha <hatrang@google.com>2023-12-06 01:08:33 +0000
committerJane Ha <hatrang@google.com>2023-12-06 01:08:33 +0000
commit50f8b6c2c6e2e9668489bbce6d0d9270af1d3f9f (patch)
treec8bf34d3dabe3bb4ba14434ea129897688d5e4a3
parent4c1798d50513e5c5c10b314f4c90ac3e697dc25d (diff)
downloadSystemUI-50f8b6c2c6e2e9668489bbce6d0d9270af1d3f9f.tar.gz
Fix CarSystemBarControllerTest
Disable display compat toolbar when the left system bar is enable Bug: 314819692 Bug: 314819772 Test: atest CarSystemBarControllerTest Change-Id: I8100ea1ee9b8b2a86690509ccee281e6ab4ff979
-rw-r--r--tests/src/com/android/systemui/car/systembar/CarSystemBarControllerTest.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/src/com/android/systemui/car/systembar/CarSystemBarControllerTest.java b/tests/src/com/android/systemui/car/systembar/CarSystemBarControllerTest.java
index 561871ed..789a2ce8 100644
--- a/tests/src/com/android/systemui/car/systembar/CarSystemBarControllerTest.java
+++ b/tests/src/com/android/systemui/car/systembar/CarSystemBarControllerTest.java
@@ -257,6 +257,7 @@ public class CarSystemBarControllerTest extends SysuiTestCase {
@Test
public void testGetLeftWindow_leftDisabled_returnsNull() {
+ mTestableResources.addOverride(R.integer.config_showDisplayCompatToolbarOnSystemBar, 0);
mTestableResources.addOverride(R.bool.config_enableLeftSystemBar, false);
mCarSystemBar = createSystemBarController();
ViewGroup window = mCarSystemBar.getLeftWindow();
@@ -265,6 +266,7 @@ public class CarSystemBarControllerTest extends SysuiTestCase {
@Test
public void testGetLeftWindow_leftEnabled_returnsWindow() {
+ mTestableResources.addOverride(R.integer.config_showDisplayCompatToolbarOnSystemBar, 0);
mTestableResources.addOverride(R.bool.config_enableLeftSystemBar, true);
mCarSystemBar = createSystemBarController();
@@ -275,6 +277,7 @@ public class CarSystemBarControllerTest extends SysuiTestCase {
@Test
public void testGetLeftWindow_leftEnabled_calledTwice_returnsSameWindow() {
+ mTestableResources.addOverride(R.integer.config_showDisplayCompatToolbarOnSystemBar, 0);
mTestableResources.addOverride(R.bool.config_enableLeftSystemBar, true);
mCarSystemBar = createSystemBarController();
@@ -361,6 +364,7 @@ public class CarSystemBarControllerTest extends SysuiTestCase {
@Test
public void testSetLeftWindowVisibility_setTrue_isVisible() {
+ mTestableResources.addOverride(R.integer.config_showDisplayCompatToolbarOnSystemBar, 0);
mTestableResources.addOverride(R.bool.config_enableLeftSystemBar, true);
mCarSystemBar = createSystemBarController();
@@ -372,6 +376,7 @@ public class CarSystemBarControllerTest extends SysuiTestCase {
@Test
public void testSetLeftWindowVisibility_setFalse_isGone() {
+ mTestableResources.addOverride(R.integer.config_showDisplayCompatToolbarOnSystemBar, 0);
mTestableResources.addOverride(R.bool.config_enableLeftSystemBar, true);
mCarSystemBar = createSystemBarController();