Checking in LEDE GUI for device registration; this was ported from the implementation...
[iot2.git] / others / lede-gui / src / androidTest / java / com / example / lede2 / ExampleInstrumentedTest.java
diff --git a/others/lede-gui/src/androidTest/java/com/example/lede2/ExampleInstrumentedTest.java b/others/lede-gui/src/androidTest/java/com/example/lede2/ExampleInstrumentedTest.java
new file mode 100644 (file)
index 0000000..26dadde
--- /dev/null
@@ -0,0 +1,26 @@
+package com.example.lede2;\r
+\r
+import android.content.Context;\r
+import android.support.test.InstrumentationRegistry;\r
+import android.support.test.runner.AndroidJUnit4;\r
+\r
+import org.junit.Test;\r
+import org.junit.runner.RunWith;\r
+\r
+import static org.junit.Assert.*;\r
+\r
+/**\r
+ * Instrumentation test, which will execute on an Android device.\r
+ *\r
+ * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>\r
+ */\r
+@RunWith(AndroidJUnit4.class)\r
+public class ExampleInstrumentedTest {\r
+    @Test\r
+    public void useAppContext() throws Exception {\r
+        // Context of the app under test.\r
+        Context appContext = InstrumentationRegistry.getTargetContext();\r
+\r
+        assertEquals("com.example.lede2", appContext.getPackageName());\r
+    }\r
+}\r