summaryrefslogtreecommitdiff
path: root/platform/android/MapboxGLAndroidSDKTestApp/src/androidTest/java/com/mapbox/mapboxsdk/testapp/espresso/MapFragmentActivityTest.java
blob: d7522b2d7f893a7a41bd05334df04dfedab25feb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
package com.mapbox.mapboxsdk.testapp.espresso;

import android.support.test.rule.ActivityTestRule;
import android.support.test.runner.AndroidJUnit4;
import android.test.suitebuilder.annotation.LargeTest;

import com.mapbox.mapboxsdk.testapp.activity.fragment.MapFragmentActivity;
import com.mapbox.mapboxsdk.testapp.R;

import org.junit.Before;
import org.junit.Rule;
import org.junit.Test;
import org.junit.runner.RunWith;

/**
 * Tests on MapFragmentActivity
 */
@RunWith(AndroidJUnit4.class)
@LargeTest
public class MapFragmentActivityTest extends BaseTest {

    @Rule
    public ActivityTestRule<MapFragmentActivity> mActivityRule = new ActivityTestRule<>(
            MapFragmentActivity.class);

    private MapFragmentActivity mActivity = null;

    @Before
    public void setActivity() {
        mActivity = mActivityRule.getActivity();
    }

    @Test
    public void testSanity() {
        checkViewIsDisplayed(R.id.fragment_container);
    }

    // FIXME need a way to check if fragment was correctly added to Activity
}