我创建了一个hello world demo并尝试使用带有以下链接的Monkey talk创建一个instumented apk http://www.jiahaoliuliu.com/2015/02/monkey-talk-integration-with-android.html
我在app模块中的build.gradle文件中找不到任何错误 下面是我的build.gradle
apply plugin: 'com.android.application'
apply plugin: 'android-aspectj'
android {
compileSdkVersion 23
buildToolsVersion "23.0.2"
defaultConfig {
applicationId "packagename"
minSdkVersion 15
targetSdkVersion 21
}
lintOptions {
checkReleaseBuilds false
}
packagingOptions {
exclude 'META-INF/DEPENDENCIES'
exclude 'META-INF/NOTICE'
exclude 'META-INF/LICENSE'
exclude 'META-INF/LICENSE.txt'
exclude 'META-INF/NOTICE.txt'
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
}
monkeytalk.initWith(buildTypes.debug)
monkeytalk {
applicationIdSuffix ".monkey"
}
}
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:support-v4:21.0.1'
// GCM gradles
compile 'com.google.android.gms:play-services-gcm:8.4.0'
// Map & location
compile 'com.google.android.gms:play-services-maps:8.4.0'
compile 'com.google.android.gms:play-services-location:8.4.0'
//facebook
compile 'com.facebook.android:facebook-android-sdk:4.9.0'
compile project(':calenderLib')
// Dependency for Google + Sign-In
compile 'com.google.android.gms:play-services-plus:8.4.0'
// Dependency for Google Sign-In
compile 'com.google.android.gms:play-services-auth:8.4.0'
compile 'com.google.guava:guava:18.0'
compile 'joda-time:joda-time:2.4'
compile 'com.google.android.gms:play-services-appindexing:8.4.0'
compile files('monkey-libs/monkeytalk-agent-2.0.10.jar')
monkeytalkCompile fileTree(dir: 'monkey-libs', include: ['*.jar'])
}
运行应用程序时我发现以下错误,
错误:任务':app:compileDebugJavaWithJavac'执行失败。 >没有这样的属性:类的bootClasspath:com.android.build.gradle.AppPlugin
我正在使用android studio版本1.5.1
和Monkey talk monkeytalk-2.0.10-win64
错误截屏
答案 0 :(得分:0)
请参阅此文档link
无需使用
monkeytalkCompile fileTree(dir:' monkey-libs',include:[' * .jar'])
这使我在运行项目时出错
无需撰写
monkeytalk.initWith(buildTypes.debug) monkeytalk { applicationIdSuffix" .monkey" }
只需使用:
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
我认为这会有所帮助,如果有人遇到问题,请告诉我。我的构建在monkeytalk IDE上成功运行