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

Commit e36c7112 authored by Abodunrinwa Toki's avatar Abodunrinwa Toki
Browse files

Fix failing TextActivityTest.

It seems like setOrientation(...) is not working.
Instead, fix the orientation of TextViewActivity to portrait.
See: I2f9372997f8301d800109981c6e1a6d4419b641d
Bug: 24495166

Change-Id: I0c5480b7ce6ba1fb8e4e4e3daabe94ebccca4dfd
parent 339e884b
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -136,7 +136,9 @@
            </intent-filter>
        </activity>

        <activity android:name="android.widget.TextViewActivity" android:label="TextViewActivity">
        <activity android:name="android.widget.TextViewActivity"
                android:label="TextViewActivity"
                android:screenOrientation="portrait">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.FRAMEWORK_INSTRUMENTATION_TEST" />
+1 −5
Original line number Diff line number Diff line
@@ -36,7 +36,6 @@ import com.android.frameworks.coretests.R;

import android.test.ActivityInstrumentationTestCase2;
import android.test.suitebuilder.annotation.SmallTest;
import android.util.OrientationUtil;
import android.view.KeyEvent;

/**
@@ -44,16 +43,13 @@ import android.view.KeyEvent;
 */
public class TextViewActivityTest extends ActivityInstrumentationTestCase2<TextViewActivity>{

    private OrientationUtil mOrientationUtil;

    public TextViewActivityTest() {
        super(TextViewActivity.class);
    }

    @Override
    public void setUp() {
        mOrientationUtil = OrientationUtil.initializeAndStartActivityIfNotStarted(this);
        mOrientationUtil.setPortraitOrientation();
        getActivity();
    }

    @SmallTest