Search in sources :

Example 26 with MediumTest

use of android.test.suitebuilder.annotation.MediumTest in project android_frameworks_base by ParanoidAndroid.

the class ViewGroupChildrenTest method testRemoveChild.

@UiThreadTest
@MediumTest
public void testRemoveChild() throws Exception {
    View view = createView("1");
    mGroup.addView(view);
    ViewAsserts.assertGroupIntegrity(mGroup);
    mGroup.removeView(view);
    ViewAsserts.assertGroupIntegrity(mGroup);
    ViewAsserts.assertGroupNotContains(mGroup, view);
    assertEquals(0, mGroup.getChildCount());
    assertNull(view.getParent());
}
Also used : TextView(android.widget.TextView) View(android.view.View) UiThreadTest(android.test.UiThreadTest) MediumTest(android.test.suitebuilder.annotation.MediumTest)

Example 27 with MediumTest

use of android.test.suitebuilder.annotation.MediumTest in project android_frameworks_base by ParanoidAndroid.

the class ViewStubTest method testInflated.

@UiThreadTest
@MediumTest
public void testInflated() throws Exception {
    final StubbedView activity = getActivity();
    final ViewStub stub = (ViewStub) activity.findViewById(R.id.viewStub);
    final View swapped = stub.inflate();
    assertNotNull("The inflated view is null", swapped);
}
Also used : ViewStub(android.view.ViewStub) StubbedView(android.view.StubbedView) StubbedView(android.view.StubbedView) View(android.view.View) UiThreadTest(android.test.UiThreadTest) MediumTest(android.test.suitebuilder.annotation.MediumTest)

Example 28 with MediumTest

use of android.test.suitebuilder.annotation.MediumTest in project android_frameworks_base by ParanoidAndroid.

the class ViewStubTest method testInflatedId.

@UiThreadTest
@MediumTest
public void testInflatedId() throws Exception {
    final StubbedView activity = getActivity();
    final ViewStub stub = (ViewStub) activity.findViewById(R.id.viewStubWithId);
    final View swapped = stub.inflate();
    assertNotNull("The inflated view is null", swapped);
    assertTrue("The inflated view has no id", swapped.getId() != View.NO_ID);
    assertTrue("The inflated view has the wrong id", swapped.getId() == R.id.stub_inflated);
}
Also used : ViewStub(android.view.ViewStub) StubbedView(android.view.StubbedView) StubbedView(android.view.StubbedView) View(android.view.View) UiThreadTest(android.test.UiThreadTest) MediumTest(android.test.suitebuilder.annotation.MediumTest)

Example 29 with MediumTest

use of android.test.suitebuilder.annotation.MediumTest in project android_frameworks_base by ParanoidAndroid.

the class ViewStubTest method testStubbed.

@MediumTest
public void testStubbed() throws Exception {
    final StubbedView activity = getActivity();
    final View stub = activity.findViewById(R.id.viewStub);
    assertNotNull("The ViewStub does not exist", stub);
}
Also used : StubbedView(android.view.StubbedView) StubbedView(android.view.StubbedView) View(android.view.View) MediumTest(android.test.suitebuilder.annotation.MediumTest)

Example 30 with MediumTest

use of android.test.suitebuilder.annotation.MediumTest in project android_frameworks_base by ParanoidAndroid.

the class IncludeTest method testIncludedWithVisibility.

@MediumTest
public void testIncludedWithVisibility() throws Exception {
    final Include activity = getActivity();
    final View button1 = activity.findViewById(R.id.included_button_visibility);
    assertEquals("Included button should be invisible", View.INVISIBLE, button1.getVisibility());
}
Also used : Include(android.view.Include) View(android.view.View) MediumTest(android.test.suitebuilder.annotation.MediumTest)

Aggregations

MediumTest (android.test.suitebuilder.annotation.MediumTest)1023 View (android.view.View)246 ListView (android.widget.ListView)151 Cursor (android.database.Cursor)116 Handler (android.os.Handler)116 Suppress (android.test.suitebuilder.annotation.Suppress)73 TextView (android.widget.TextView)67 ContentValues (android.content.ContentValues)63 ServiceStatus (com.vodafone360.people.service.ServiceStatus)60 SQLiteCursor (android.database.sqlite.SQLiteCursor)54 SQLiteStatement (android.database.sqlite.SQLiteStatement)49 IOException (java.io.IOException)49 UiThreadTest (android.test.UiThreadTest)48 Message (android.os.Message)43 LogRec (com.android.internal.util.StateMachine.LogRec)42 Intent (android.content.Intent)40 ContentResolver (android.content.ContentResolver)37 GridView (android.widget.GridView)36 InputStream (java.io.InputStream)36 ByteArrayInputStream (java.io.ByteArrayInputStream)35