File tree Expand file tree Collapse file tree
androidTest/java/cn/refactor/multistatelayoutdemo
test/java/cn/refactor/multistatelayoutdemo Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -21,7 +21,7 @@ allprojects {
2121##### Step 2. Add the dependency
2222~~~ xml
2323dependencies {
24- compile 'com.github.andyxialm:MultiStateLayout:0.0.7 '
24+ compile 'com.github.andyxialm:MultiStateLayout:0.0.8 '
2525}
2626~~~
2727
@@ -41,7 +41,7 @@ dependencies {
4141<dependency >
4242 <groupId >com.github.andyxialm</groupId >
4343 <artifactId >MultiStateLayout</artifactId >
44- <version >0.0.7 </version >
44+ <version >0.0.8 </version >
4545</dependency >
4646~~~
4747
Original file line number Diff line number Diff line change 1+ package cn .refactor .multistatelayoutdemo ;
2+
3+ import android .content .Context ;
4+ import android .support .test .InstrumentationRegistry ;
5+ import android .support .test .runner .AndroidJUnit4 ;
6+
7+ import org .junit .Test ;
8+ import org .junit .runner .RunWith ;
9+
10+ import static org .junit .Assert .*;
11+
12+ /**
13+ * Instrumentation test, which will execute on an Android device.
14+ *
15+ * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
16+ */
17+ @ RunWith (AndroidJUnit4 .class )
18+ public class ExampleInstrumentedTest {
19+ @ Test
20+ public void useAppContext () throws Exception {
21+ // Context of the app under test.
22+ Context appContext = InstrumentationRegistry .getTargetContext ();
23+
24+ assertEquals ("cn.refactor.multistatelayoutdemo" , appContext .getPackageName ());
25+ }
26+ }
Original file line number Diff line number Diff line change 1+ package cn .refactor .multistatelayoutdemo ;
2+
3+ import org .junit .Test ;
4+
5+ import static org .junit .Assert .*;
6+
7+ /**
8+ * Example local unit test, which will execute on the development machine (host).
9+ *
10+ * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
11+ */
12+ public class ExampleUnitTest {
13+ @ Test
14+ public void addition_isCorrect () throws Exception {
15+ assertEquals (4 , 2 + 2 );
16+ }
17+ }
You can’t perform that action at this time.
0 commit comments