It seems gradle tags are misplaced in build.gradle
script file . Please look at below build.gradle
file and do the necessary changes.
buildscript {
repositories {
mavenCentral() // This only tells gradle where the to find the android plugin
}
dependencies {
classpath 'com.android.tools.build:gradle:0.7.3'
}
}
apply plugin: 'android'
repositories {
mavenCentral()
mavenLocal()
}
dependencies {
compile 'com.nineoldandroids:library:2.4.0'
compile 'com.android.support:support-v4:19.0.0'
compile 'com.android.support:appcompat-v7:19.0.0'
compile 'com.google.android.gms:play-services:4.0.30'
compile 'com.squareup:otto:1.3.4'
compile 'com.squareup.dagger:dagger:1.1.0'
compile 'com.squareup.dagger:dagger-compiler:1.1.0'
compile 'com.squareup.okhttp:okhttp:1.2.1'
compile 'com.squareup.retrofit:retrofit:1.2.1'
compile 'com.google.code.gson:gson:2.2.4'
compile 'com.google.guava:guava:15.0'
compile 'com.google.maps.android:android-maps-utils:0.2.1'
compile 'se.emilsjolander:StickyScrollViewItems:1.1.0'
compile fileTree(dir: 'libs', include: '*.jar')
instrumentTestCompile 'com.jayway.android.robotium:robotium-solo:4.3.1'
instrumentTestCompile 'info.cukes:cucumber-android:1.1.5'
instrumentTestCompile 'info.cukes:cucumber-junit:1.1.5'
instrumentTestCompile 'info.cukes:cucumber-picocontainer:1.1.5'
instrumentTestCompile 'info.cukes:gherkin:2.12.2'
}
android {
testBuildType "debug"
compileSdkVersion 19
buildToolsVersion '19.0.0'
defaultConfig {
minSdkVersion 9
targetSdkVersion 19
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_6
targetCompatibility JavaVersion.VERSION_1_6
}
signingConfigs {
debug {
storeFile file('../certificate/debug.keystore')
}
}
sourceSets {
instrumentTest {
java.srcDirs = ['src/instrumentTest/java','src/instrumentTest/cucumber']
}
main {
manifest.srcFile 'src/main/AndroidManifest.xml'
java.srcDirs = ['src/main/java', 'AndroidRSS/src']
resources.srcDirs = ['src/main/res']
aidl.srcDirs = ['src/main/aidl']
renderscript.srcDirs = ['src/main/rs']
res.srcDirs = ['src/main/res']
assets.srcDirs = ['src/main/assets']
}
}
}
What is there inside src/instrumentTest/cucumber
directory. If you have any java classes there I think you have to move then in java directory of test project.