1. java.lang.RuntimeException: java.lang.RuntimeException: com.android.builder.dexing.DexArchiveMergerException: Unable to merge dex
引入了相同的包名
2.Expected a string but was BEGIN_OBJECT at line 1 column 2 path $
不让retrofit2自动替我解析json
解决:将返回类型换成 JSONObject
3.The SourceSet 'instrumentTest' is not recognized by the Android Gradle Plugin. Perhaps you misspelled something?
解决办法
用 androidTest 替换 instrumentTest,编译运行即可。