android-studio

AndroidManifest.xml and tests in Android Studio

点点圈 提交于 2020-01-15 12:23:49
问题 I have a basic Android project with an application sources directory and tests sources directory set up by the Android Project template. I have read that Android tests uses an Androidmanifest.xml specific to the running tests in which we have to specify the instrumentation type and the target package: <instrumentation android:name="android.test.InstrumentationTestRunner" android:targetPackage="com.mypackage.app" /> In Android Studio,I can run tests with android tests configuration without

AndroidManifest.xml and tests in Android Studio

ぐ巨炮叔叔 提交于 2020-01-15 12:22:52
问题 I have a basic Android project with an application sources directory and tests sources directory set up by the Android Project template. I have read that Android tests uses an Androidmanifest.xml specific to the running tests in which we have to specify the instrumentation type and the target package: <instrumentation android:name="android.test.InstrumentationTestRunner" android:targetPackage="com.mypackage.app" /> In Android Studio,I can run tests with android tests configuration without

Null Pointer Exception and getMapAsync Error

自闭症网瘾萝莉.ら 提交于 2020-01-15 11:58:09
问题 I'm a student programmer and currently coding a Route Guide App. Suddenly, while trying to open my android application, it crashes. So, I tried searching for a lot of tutorials on how to fix the error message that I got. Unfortunately, I ran out of hope and came here to seek for help. I keep getting this on Console: $ adb shell am start -n "com.garate.taraj/com.garate.taraj.MapsActivity" -a android.intent.action.MAIN -c android.intent.category.LAUNCHER -D Waiting for application to come

Where is InstallDebug in Gradle? How to install a test Android App?

淺唱寂寞╮ 提交于 2020-01-15 11:23:28
问题 I'm trying to install an Android app I'm developing in Android Studio on my test device. I normally do this with the Gradle task called "InstallDebug. In my newly created project however, I now don't see this task in my list of Gradle Tasks anymore. The only two things I see starting with Install* are installDefaultFlavorDebug installDefaultFlavorTest Does anybody know which Gradle Task I need to use to install my app on my phone to test it? 回答1: Now you will find this tasks: gradlew install

Android Studio 3.0 RunTimeException

蹲街弑〆低调 提交于 2020-01-15 10:43:07
问题 I've installed Android Studio 3.0 on VirtualBox, OS Lubuntu. During making project, there is an exception: Error:java.util.concurrent.ExecutionException: java.lang.RuntimeException: No server to serve request. Check logs for details. Error:Execution failed for task ':app:mergeDebugResources'. Error: java.util.concurrent.ExecutionException: java.lang.RuntimeException: No server to serve request. Check logs for details. I've tried oracle-jdk8 and OpenJdk. The same promlem. 回答1: Not quite sure

Android Studio 3.0 RunTimeException

痴心易碎 提交于 2020-01-15 10:43:02
问题 I've installed Android Studio 3.0 on VirtualBox, OS Lubuntu. During making project, there is an exception: Error:java.util.concurrent.ExecutionException: java.lang.RuntimeException: No server to serve request. Check logs for details. Error:Execution failed for task ':app:mergeDebugResources'. Error: java.util.concurrent.ExecutionException: java.lang.RuntimeException: No server to serve request. Check logs for details. I've tried oracle-jdk8 and OpenJdk. The same promlem. 回答1: Not quite sure

Android Studio 3.0 RunTimeException

此生再无相见时 提交于 2020-01-15 10:42:47
问题 I've installed Android Studio 3.0 on VirtualBox, OS Lubuntu. During making project, there is an exception: Error:java.util.concurrent.ExecutionException: java.lang.RuntimeException: No server to serve request. Check logs for details. Error:Execution failed for task ':app:mergeDebugResources'. Error: java.util.concurrent.ExecutionException: java.lang.RuntimeException: No server to serve request. Check logs for details. I've tried oracle-jdk8 and OpenJdk. The same promlem. 回答1: Not quite sure

Android Spinner Set dropdown text direction to RTL

青春壹個敷衍的年華 提交于 2020-01-15 10:25:27
问题 How to set spinner dropdown text direction to rtl ? I know for regular texts we can use android:textDirection="rtl" but it does not work for spinner dropdown text. Should I implement it in popup theme? How? Thanks 回答1: Try This - Add below code in Activity Spinner spinner = (Spinner) findViewById(R.id.spinner); ArrayAdapter<CharSequence> adapter = ArrayAdapter.createFromResource(this, R.array.planets_array, // android.R.layout.simple_spinner_item); R.layout.textview); // adapter

How to add prebuilt .so library in android studio 0.8.6

邮差的信 提交于 2020-01-15 10:17:12
问题 The Error I will get is Couldn't load json from loader dalvik.system.PathClassLoader[DexPathList[dexElements=[zip file "/data/app/com.uei.tools.ndktest-1.apk"],nativeLibraryDirectories=[/data/app-lib/com.uei.tools.ndktest-1, /vendor/lib, /system/lib]]]: findLibrary returned null I created a zip file of all .so files and i added into libs folder under app folder i added jar dependency from Module settings dependency. All serch resulted in sample code of old versions of android studio but there

specify .so files in build.gradle file android studio

只谈情不闲聊 提交于 2020-01-15 10:16:09
问题 This is my Directory Structure src -main -java -jniLibs -armeabi -lib1.so -lib2.so Need to understand what piece of code should be written in build gradle file for these files to be included in the build. Right now, i am getting the error of not finding the .so file. java.lang.UnsatisfiedLinkError: nativeLibraryDirectories=[/vendor/lib, /system/lib]]] couldn't find "libFPEComponent.so" Following solution by H.Brooks I have got to add here My Git repository: My bUild.gradle file apply plugin: