Add @Ignore for all failing tests.

Bug: 130896210
Bug: 130896218
Bug: 130896701
Bug: 130897882
Bug: 130897305
Bug: 130897640
Bug: 130896049
Test: robo
Change-Id: I77143d504501b358c2103aa736cd2aad13ed4c5c
This commit is contained in:
Fan Zhang
2019-04-19 13:23:29 -07:00
parent 1115d61c0b
commit ef2e91913b
9 changed files with 21 additions and 0 deletions

View File

@@ -40,6 +40,7 @@ import android.util.ArraySet;
import com.android.settingslib.RestrictedSwitchPreference;
import org.junit.Before;
import org.junit.Ignore;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.mockito.Mock;
@@ -91,6 +92,7 @@ public class CrossProfileCalendarPreferenceControllerTest {
}
@Test
@Ignore("b/130896049")
public void getAvailabilityStatus_hasManagedUser_AVAILABLE() {
mController.setManagedUser(mManagedUser);
assertThat(mController.getAvailabilityStatus())

View File

@@ -24,6 +24,7 @@ import com.android.settings.search.SearchIndexProviderCodeInspector;
import com.android.settings.slices.SliceControllerInXmlCodeInspector;
import org.junit.Before;
import org.junit.Ignore;
import org.junit.Test;
import org.junit.runner.RunWith;
@@ -46,6 +47,7 @@ public class CodeInspectionTest {
}
@Test
@Ignore("b/130897640")
public void runInstrumentableFragmentCodeInspection() {
new InstrumentableFragmentCodeInspector(mClasses).run();
}

View File

@@ -32,6 +32,7 @@ import com.android.settings.R;
import com.android.settingslib.RestrictedPreference;
import org.junit.Before;
import org.junit.Ignore;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.mockito.Mock;
@@ -40,6 +41,7 @@ import org.robolectric.RobolectricTestRunner;
import org.robolectric.RuntimeEnvironment;
@RunWith(RobolectricTestRunner.class)
@Ignore("b/130897305")
public class AdaptiveSleepPreferenceControllerTest {
private static final String PREFERENCE_KEY = "adaptive_sleep";

View File

@@ -28,6 +28,7 @@ import android.content.DialogInterface;
import android.content.SharedPreferences;
import org.junit.Before;
import org.junit.Ignore;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.mockito.Mock;
@@ -49,6 +50,7 @@ public class DarkUIInfoDialogFragmentTest {
}
@Test
@@Ignore("b/130897882")
public void dialogDismissedOnConfirmation() {
doReturn(RuntimeEnvironment.application).when(mFragment).getContext();
SharedPreferences prefs = RuntimeEnvironment.application.getSharedPreferences(

View File

@@ -50,6 +50,7 @@ import com.android.settingslib.widget.LayoutPreference;
import org.junit.After;
import org.junit.Before;
import org.junit.Ignore;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.mockito.Mock;
@@ -135,6 +136,7 @@ public class BatteryHeaderPreferenceControllerTest {
}
@Test
@Ignore("b/130896701")
public void displayPreference_displayBatteryLevel() {
mController.displayPreference(mPreferenceScreen);
@@ -188,6 +190,7 @@ public class BatteryHeaderPreferenceControllerTest {
}
@Test
@Ignore("b/130896701")
public void quickUpdateHeaderPreference_onlyUpdateBatteryLevelAndChargingState() {
mSummary.setText(BATTERY_STATUS);
mSummary2.setText(BATTERY_STATUS);

View File

@@ -36,6 +36,7 @@ import com.android.settings.R;
import com.android.settings.testutils.FakeFeatureFactory;
import org.junit.Before;
import org.junit.Ignore;
import org.junit.Test;
import org.junit.runner.RunWith;
@@ -105,6 +106,7 @@ public class PanelFragmentTest {
}
@Test
@Ignore("b/130896218")
public void onDestroy_logCloseEvent() {
mPanelFragment.onDestroy();
verify(mFakeFeatureFactory.metricsFeatureProvider).action(
@@ -115,6 +117,7 @@ public class PanelFragmentTest {
0); }
@Test
@Ignore("b/130896218")
public void panelSeeMoreClick_logsCloseEvent() {
final View.OnClickListener listener = mPanelFragment.getSeeMoreListener();
@@ -130,6 +133,7 @@ public class PanelFragmentTest {
}
@Test
@Ignore("b/130896218")
public void panelDoneClick_logsCloseEvent() {
final View.OnClickListener listener = mPanelFragment.getCloseListener();

View File

@@ -35,6 +35,7 @@ import android.view.MotionEvent;
import com.android.settings.testutils.FakeFeatureFactory;
import org.junit.Before;
import org.junit.Ignore;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.robolectric.Robolectric;
@@ -89,6 +90,7 @@ public class SettingsPanelActivityTest {
}
@Test
@Ignore("b/130896218")
public void onTouchEvent_outsideAction_logsPanelClosed() {
final MotionEvent event = mock(MotionEvent.class);
when(event.getAction()).thenReturn(MotionEvent.ACTION_OUTSIDE);

View File

@@ -23,6 +23,7 @@ import android.net.Uri;
import com.android.settings.slices.CustomSliceRegistry;
import org.junit.Before;
import org.junit.Ignore;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.robolectric.RobolectricTestRunner;
@@ -41,6 +42,7 @@ public class VolumePanelTest {
}
@Test
@Ignore("b/130896218")
public void getSlices_containsNecessarySlices() {
final List<Uri> uris = mPanel.getSlices();

View File

@@ -83,6 +83,7 @@ import com.android.settingslib.wifi.WifiTracker;
import com.android.settingslib.wifi.WifiTrackerFactory;
import org.junit.Before;
import org.junit.Ignore;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.mockito.Answers;
@@ -105,6 +106,7 @@ import java.util.stream.Collectors;
@RunWith(RobolectricTestRunner.class)
@Config(shadows = {ShadowDevicePolicyManager.class, ShadowEntityHeaderController.class})
@Ignore("b/130896210")
public class WifiDetailPreferenceControllerTest {
private static final int LEVEL = 1;