0

When I run robotium (5.2.1) tests from android studio 1.0 RC 2, I get this following error ==>

:app:shrinkDebugTestMultiDexComponents FAILED

Error:Execution failed for task ':app:shrinkDebugTestMultiDexComponents'.> java.io.IOException: The output jar is empty. Did you specify the proper '-keep' options?

I have no problem to run the application "in normal mode".

Do you know where is my problem ?

Thx in advance

EDIT

According to Jared Burrows's answer I can pass task shrinkDebugTestMultiDexComponents but now I have this problem

:app:packageAllDebugTestClassesForMultiDex FAILED

Error:Execution failed for task ':app:packageAllDebugTestClassesForMultiDex'.> java.util.zip.ZipException: duplicate entry: android/support/multidex/BuildConfig.class
mrroboaat
  • 5,602
  • 7
  • 37
  • 65
  • 1
    I am not sure Robotium supports multidex but you should look into the correct setup here: https://developer.android.com/tools/building/multidex.html. Try to use the test multidex instrumentation support. – Jared Burrows Dec 03 '14 at 17:38
  • Thx for the link. I think doc is not very clear. Tests worked fine with robotium without multi dex support and now tests are broken. – mrroboaat Dec 04 '14 at 09:26
  • Do you need multidex? Did you hit the 65k+ limit? Try using proguard? – Jared Burrows Dec 04 '14 at 13:37
  • Yes I hit the 65k+ limit. I've already used proguard but I have some trouble. I found this link https://groups.google.com/forum/#!topic/adt-dev/i7g7wkpvWVc . I think this is the reason why I have this issue – mrroboaat Dec 04 '14 at 13:40
  • possible duplicate of [Android gradle plugin multidex ZipException](http://stackoverflow.com/questions/27033260/android-gradle-plugin-multidex-zipexception) – dcow Jan 15 '15 at 19:54

0 Answers0