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

Commit 5fdd4d1c authored by Android Build Coastguard Worker's avatar Android Build Coastguard Worker
Browse files

Snap for 8698871 from 7b031108 to tm-qpr1-release

Change-Id: I0622110dd20399709dcba3cc825de0db0e689d5d
parents 210bf99c 7b031108
Loading
Loading
Loading
Loading
+6 −0
Original line number Original line Diff line number Diff line
@@ -29,6 +29,8 @@ import android.content.pm.ActivityInfo;
import android.graphics.Paint;
import android.graphics.Paint;
import android.os.Build;
import android.os.Build;
import android.os.ParcelFileDescriptor;
import android.os.ParcelFileDescriptor;
import android.support.test.uiautomator.UiDevice;
import android.view.KeyEvent;


import androidx.fragment.app.FragmentManager;
import androidx.fragment.app.FragmentManager;
import androidx.test.filters.LargeTest;
import androidx.test.filters.LargeTest;
@@ -75,6 +77,10 @@ public class DialogUiTest {
        mFileActivityIntent = new Intent(Intent.ACTION_OPEN_DOCUMENT_TREE);
        mFileActivityIntent = new Intent(Intent.ACTION_OPEN_DOCUMENT_TREE);
        mFragmentManager = mActivityTestRule.getActivity().getSupportFragmentManager();
        mFragmentManager = mActivityTestRule.getActivity().getSupportFragmentManager();
        mScreenDensitySession = new ScreenDensitySession();
        mScreenDensitySession = new ScreenDensitySession();

        final UiDevice device = UiDevice.getInstance(InstrumentationRegistry.getInstrumentation());
        device.pressKeyCode(KeyEvent.KEYCODE_WAKEUP);
        device.pressKeyCode(KeyEvent.KEYCODE_MENU);
    }
    }


    @After
    @After
+2 −0
Original line number Original line Diff line number Diff line
@@ -29,6 +29,7 @@ import android.net.Uri;
import android.os.Bundle;
import android.os.Bundle;
import android.os.RemoteException;
import android.os.RemoteException;
import android.os.SystemClock;
import android.os.SystemClock;
import android.provider.MediaStore;
import android.provider.Settings;
import android.provider.Settings;
import android.support.test.uiautomator.UiObjectNotFoundException;
import android.support.test.uiautomator.UiObjectNotFoundException;
import android.text.TextUtils;
import android.text.TextUtils;
@@ -131,6 +132,7 @@ public class FileCopyUiTest extends ActivityTest<FilesActivity> {
        mPreTestStayAwakeValue = Settings.Global.getInt(context.getContentResolver(),
        mPreTestStayAwakeValue = Settings.Global.getInt(context.getContentResolver(),
                Settings.Global.STAY_ON_WHILE_PLUGGED_IN);
                Settings.Global.STAY_ON_WHILE_PLUGGED_IN);
        device.executeShellCommand("settings put global stay_on_while_plugged_in 3");
        device.executeShellCommand("settings put global stay_on_while_plugged_in 3");
        MediaStore.waitForIdle(context.getContentResolver());


        mDeviceLabel = Settings.Global.getString(context.getContentResolver(),
        mDeviceLabel = Settings.Global.getString(context.getContentResolver(),
                Settings.Global.DEVICE_NAME);
                Settings.Global.DEVICE_NAME);