Can't run Roboelectric test

2020-03-03 07:26发布

I keep on getting

java.lang.NoClassDefFoundError: android/content/pm/PackageManager$NameNotFoundException ... java.lang.ClassNotFoundException: couldn't load android.content.pm.PackageManager$NameNotFoundException... Caused by: java.util.zip.ZipException: invalid LOC header (bad signature)

Any idea what causes this and how to get it fixed?

2条回答
地球回转人心会变
2楼-- · 2020-03-03 08:12

your jar file may be corruptedso re add the jar file orrebuild the path of jar file ... clean the project and re run it.

查看更多
放我归山
3楼-- · 2020-03-03 08:17

You need install sources for android-21 from Android SDK

查看更多
登录 后发表回答