Bitliker 8 лет назад
Родитель
Сommit
bd4e65fec2

+ 1 - 0
app_modular/appcontact/.gitignore

@@ -0,0 +1 @@
+/build

+ 27 - 0
app_modular/appcontact/build.gradle

@@ -0,0 +1,27 @@
+apply plugin: 'com.android.library'
+
+
+android {
+    compileSdkVersion rootProject.ext.android.compileSdkVersion
+    buildToolsVersion rootProject.ext.android.buildToolsVersion
+    defaultConfig {
+        minSdkVersion rootProject.ext.android.minSdkVersion
+        targetSdkVersion rootProject.ext.android.targetSdkVersion
+        versionCode rootProject.ext.android.versionCode
+        versionName rootProject.ext.android.versionName
+    }
+    buildTypes {
+        release {
+            minifyEnabled false
+            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
+        }
+    }
+}
+
+dependencies {
+    compile fileTree(include: ['*.jar'], dir: 'libs')
+    testCompile deps.junit
+    compile deps.appcompatV7
+    compile project(':common')
+    compile project(':appworks')
+}

+ 25 - 0
app_modular/appcontact/proguard-rules.pro

@@ -0,0 +1,25 @@
+# Add project specific ProGuard rules here.
+# By default, the flags in this file are appended to flags specified
+# in C:\Users\Bitliker\AppData\Local\Android\Sdk/tools/proguard/proguard-android.txt
+# You can edit the include path and order by changing the proguardFiles
+# directive in build.gradle.
+#
+# For more details, see
+#   http://developer.android.com/guide/developing/tools/proguard.html
+
+# Add any project specific keep options here:
+
+# If your project uses WebView with JS, uncomment the following
+# and specify the fully qualified class name to the JavaScript interface
+# class:
+#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
+#   public *;
+#}
+
+# Uncomment this to preserve the line number information for
+# debugging stack traces.
+#-keepattributes SourceFile,LineNumberTable
+
+# If you keep the line number information, uncomment this to
+# hide the original source file name.
+#-renamesourcefileattribute SourceFile

+ 26 - 0
app_modular/appcontact/src/androidTest/java/com/uas/appcontact/ExampleInstrumentedTest.java

@@ -0,0 +1,26 @@
+package com.uas.appcontact;
+
+import android.content.Context;
+import android.support.test.InstrumentationRegistry;
+import android.support.test.runner.AndroidJUnit4;
+
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+import static org.junit.Assert.*;
+
+/**
+ * Instrumentation test, which will execute on an Android device.
+ *
+ * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
+ */
+@RunWith(AndroidJUnit4.class)
+public class ExampleInstrumentedTest {
+    @Test
+    public void useAppContext() throws Exception {
+        // Context of the app under test.
+        Context appContext = InstrumentationRegistry.getTargetContext();
+
+        assertEquals("com.uas.appcontact.test", appContext.getPackageName());
+    }
+}

+ 9 - 0
app_modular/appcontact/src/main/AndroidManifest.xml

@@ -0,0 +1,9 @@
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+
+          package="com.uas.appcontact">
+
+    <application android:allowBackup="true" android:label="@string/app_name" android:supportsRtl="true">
+
+    </application>
+
+</manifest>

+ 3 - 0
app_modular/appcontact/src/main/res/values/strings.xml

@@ -0,0 +1,3 @@
+<resources>
+    <string name="app_name">AppContact</string>
+</resources>

+ 17 - 0
app_modular/appcontact/src/test/java/com/uas/appcontact/ExampleUnitTest.java

@@ -0,0 +1,17 @@
+package com.uas.appcontact;
+
+import org.junit.Test;
+
+import static org.junit.Assert.*;
+
+/**
+ * Example local unit test, which will execute on the development machine (host).
+ *
+ * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
+ */
+public class ExampleUnitTest {
+    @Test
+    public void addition_isCorrect() throws Exception {
+        assertEquals(4, 2 + 2);
+    }
+}

+ 2 - 0
settings.gradle

@@ -11,6 +11,7 @@ include ':appworks'
 
 //业务模块
 include ':applogin'
+include ':appcontact'
 
 //第三库模块
 include ':lib-zxing'
@@ -34,6 +35,7 @@ project(':message').projectDir = new File('app_core/message')
 project(':applogin').projectDir = new File('app_modular/applogin')
 project(':appme').projectDir = new File('app_modular/appme')
 project(':appworks').projectDir = new File('app_modular/appworks')
+project(':appcontact').projectDir = new File('app_modular/appcontact')
 
 //第三库模块
 project(':lib-zxing').projectDir = new File('app_third/lib-zxing')