<分区>
我正在使用 Android Studio 1.4,每次创建新项目时都会发生同样的错误
Error:(23, 17)"Failed to resolve: junit:junit:4.12".
我看过之前关于同样问题的帖子
Error:(23, 17) Failed to resolve: junit:junit:4.12
并完成了所有给定的答案,但尽管为缺少存储库添加了 URL('http://repo1.maven.org/maven2' 和'http://jcenter.bintray.com/'),但错误仍然存在
这是我最新的build.gradle代码
apply plugin: 'com.android.application'
android {
compileSdkVersion 14
buildToolsVersion "23.0.1"
defaultConfig {
applicationId "com.example.myapplication"
minSdkVersion 14
targetSdkVersion 14
versionCode 1
versionName "1.0"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
testCompile 'junit:junit:4.12'
compile 'com.android.support:appcompat-v7:22.+'
}