Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a32d3d2f authored by Ömer Faruk Yılmaz's avatar Ömer Faruk Yılmaz
Browse files

Add CheckFlagsRule to tests with `@RequiresFlags[Enabled|Disabled]`

To enable Global lint CheckFlagsRuleDetector, we need to first fix
(or baseline) all existing errors.

For context on the development of this new lint, see b/430031210.

Bug: 435371380
Test: m .
Flag: EXEMPT test change
Change-Id: Ib21c95d8bf1702f5759e78221998a78d48f8c8ce
parent 566af37c
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -36,6 +36,8 @@ import android.media.cts.MediaProjectionRule;
import android.os.UserHandle;
import android.platform.test.annotations.RequiresFlagsDisabled;
import android.platform.test.annotations.RequiresFlagsEnabled;
import android.platform.test.flag.junit.CheckFlagsRule;
import android.platform.test.flag.junit.DeviceFlagsValueProvider;
import android.telecom.TelecomManager;
import android.telephony.TelephonyCallback;
import android.telephony.TelephonyManager;
@@ -75,6 +77,9 @@ public class MediaProjectionStoppingTest {
    private static final String STOP_DIALOG_TITLE_RES_ID = "android:id/alertTitle";
    private static final String STOP_DIALOG_CLOSE_BUTTON_RES_ID = "android:id/button2";

    @Rule
    public final CheckFlagsRule mCheckFlagsRule = DeviceFlagsValueProvider.createCheckFlagsRule();

    @Rule public MediaProjectionRule mMediaProjectionRule = new MediaProjectionRule();

    private Context mContext;