Fix conflict with dependency, Resolved versions for app diff

preview_player
Показать описание
I came across this error in Android, when I create a project with minSDK 21 and target/compile SDK 26: Error:Execution failed for task ':app:preDebugAndroidTestBuild'.
Рекомендации по теме
Комментарии
Автор

window 8.1 - x86 bit, Android Studio 3.1 Worked perfectly, thanks

HaydeerHussien
Автор

awesome!!! thanks man been looking for this solution for so long

MattyMacNJ
Автор

If you using Android Studio 3.1.+ or above

just put this in your gradle depedencies:

implementation
Overall like this:

dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation
implementation
testImplementation 'junit:junit:4.12'
androidTestImplementation
androidTestImplementation

implementation
}

androidTestImplementation
androidTestImplementation
If you use version 27 then inside dependencies version should be 1.0.2 and 3.0.2 i.e., as follows

androidTestImplementation
androidTestImplementation

ayonfesalawu
Автор

Thank you man it worked perfectly and you've earned yourself a subscriber

anchor
Автор

well
I was facing that problem...
And after seeing this..i get rid of this error.
Thankuuu

sumairaawan
Автор

One more way is Just put below in your gradle (module) depedencies:

implementation

pesh
Автор

guys you can also fix with this method: add this in build.gradle

configurations.all {
resolutionStrategy.force
}

Weboft
Автор

u have to tell from where that file was opened

hashirqadeerj
Автор

Thanks, But do I need to edit it everytime I start a new project?

nabilsayed
Автор

after restart android studio its not working

RahulKumar-kghu
visit shbcf.ru