문제

When running an Android Test from Android Studio I always get:

Failure [INSTALL_FAILED_VERSION_DOWNGRADE]

This happens even if I have uninstalled the app or created a fresh virtual device.

Any idea what this is and how to solve it?

도움이 되었습니까?

해결책

I was also getting this same error on a fresh install when testing in Android Studio. In my case I changed the name of the testPackageName. This was the same as the default package name.

Now the tests are running smoothly. I don't know why it worked but it did. Increasing the versionCode should have worked but it didn't.

다른 팁

INSTALL_FAILED_VERSION_DOWNGRADE means that the app installed on the device/simulator has lower versionCode that the build you are trying to install. You need to uninstall it first, or bump versionCode

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top