Skip to content

Commit

Permalink
build: do not mark selenium dependencies versions as strict
Browse files Browse the repository at this point in the history
https://docs.gradle.org/current/userguide/dependency_downgrade_and_exclude.html: "conflicting strict dependencies will trigger a build failure that you have to resolve".

An attempt to use `java-client:8.0.0-beta` in conjunction with Selenium 4.1.0 leads to build failures, like:
```
   > Could not resolve org.seleniumhq.selenium:selenium-remote-driver:{strictly 4.0.0}.
     Required by:
         project :xxxxxxx > io.appium:java-client:8.0.0-beta
```
In a favor of flexibility the selenium dependencies versions are not marked as strict.
  • Loading branch information
valfirst committed Dec 2, 2021
1 parent 665c7f5 commit 7af7ff8
Showing 1 changed file with 4 additions and 20 deletions.
24 changes: 4 additions & 20 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -31,21 +31,9 @@ dependencies {
compileOnly 'org.projectlombok:lombok:1.18.22'
annotationProcessor 'org.projectlombok:lombok:1.18.22'

api ('org.seleniumhq.selenium:selenium-api') {
version {
strictly "${seleniumVersion}"
}
}
api ('org.seleniumhq.selenium:selenium-remote-driver') {
version {
strictly "${seleniumVersion}"
}
}
implementation ('org.seleniumhq.selenium:selenium-support') {
version {
strictly "${seleniumVersion}"
}
}
api "org.seleniumhq.selenium:selenium-api:${seleniumVersion}"
api "org.seleniumhq.selenium:selenium-remote-driver:${seleniumVersion}"
implementation "org.seleniumhq.selenium:selenium-support:${seleniumVersion}"
implementation 'com.google.code.gson:gson:2.8.9'
implementation 'commons-codec:commons-codec:1.15'
implementation 'cglib:cglib:3.3.0'
Expand All @@ -61,11 +49,7 @@ dependencies {
testImplementation (group: 'io.github.bonigarcia', name: 'webdrivermanager', version: '5.0.3') {
exclude group: 'org.seleniumhq.selenium'
}
testImplementation ('org.seleniumhq.selenium:selenium-chrome-driver') {
version {
strictly "${seleniumVersion}"
}
}
testImplementation "org.seleniumhq.selenium:selenium-chrome-driver:${seleniumVersion}"
}

ext {
Expand Down

0 comments on commit 7af7ff8

Please sign in to comment.