tags | ||
---|---|---|
|
Android Studio 3.0 sets android:testOnly="true"
automatically on APKs that are ran from the IDE.
However, for some devices (such as OPPO R11), the test-only APKs can never be installed ...
If you face the same problem, try add this line to your '/gradle.properties':
# gradle.properties
android.injected.testOnly=false
Then the boring android:testOnly
attribute disappears. ( ͡° ͜ʖ ͡°)✧
BTW, if you do not have an 'OPPO R11' (congratulations), and just want to install such a test-only app with adb
, try:
adb install -t <test_only_apk_filename>.apk
Otherwise, you will get a failure message:
Failed to install app-debug.apk: Failure [INSTALL_FAILED_TEST_ONLY: installPackageLI]
Problem
App not installed shows when installing signed apk. The Application will install without any problem for the first time, later if I uninstall and try to reinstall the same apk it shows App not installed
Tried the following things
Note :
I had error a while creating keystore Key was created with errors: Picked up _JAVA_OPTIONS: -Xmx512M last week but this was solved. But it was resolved by deleting _JAVA_OPTIONS from environment variables I think after this the started.
No Problem with codes
I am 100% sure that it's not a problem in the code Because of I tried making signed apk for the basic login activity application. didn't change a single line of code. But the result was same
Tried the following thread
How to fix App not installed error in Android
How to Fix Android App Not Installed Error?
App not installed
Is there any way to fix APP not installed? (Exact same issue)
None of them solved the issue
Temporary fix
The only method working was disabling Google Play Protect (which is not a proper fix)