Duplicate class Error when complie

First, show my gradle. I think I set up whole things.
image

When I complie, error is showed. I have no idea. What the problem is.
This is test code.

Here is error message
Duplicate class org.apache.commons.logging.Log found in modules commons-logging-1.2.jar (commons-logging:commons-logging:1.2) and spring-jcl-5.1.0.RELEASE.jar (org.springframework:spring-jcl:5.1.0.RELEASE)
Duplicate class org.apache.commons.logging.LogFactory found in modules commons-logging-1.2.jar (commons-logging:commons-logging:1.2) and spring-jcl-5.1.0.RELEASE.jar (org.springframework:spring-jcl:5.1.0.RELEASE)
Duplicate class org.apache.commons.logging.LogFactory$1 found in modules commons-logging-1.2.jar (commons-logging:commons-logging:1.2) and spring-jcl-5.1.0.RELEASE.jar (org.springframework:spring-jcl:5.1.0.RELEASE)
Duplicate class org.apache.commons.logging.impl.NoOpLog found in modules commons-logging-1.2.jar (commons-logging:commons-logging:1.2) and spring-jcl-5.1.0.RELEASE.jar (org.springframework:spring-jcl:5.1.0.RELEASE)
Duplicate class org.apache.commons.logging.impl.SimpleLog found in modules commons-logging-1.2.jar (commons-logging:commons-logging:1.2) and spring-jcl-5.1.0.RELEASE.jar (org.springframework:spring-jcl:5.1.0.RELEASE)
Duplicate class org.openqa.selenium.SearchContext found in modules java-client-7.0.0.jar (io.appium:java-client:7.0.0) and selenium-api-3.141.59.jar (org.seleniumhq.selenium:selenium-api:3.141.59)
Duplicate class org.openqa.selenium.WebDriver found in modules java-client-7.0.0.jar (io.appium:java-client:7.0.0) and selenium-api-3.141.59.jar (org.seleniumhq.selenium:selenium-api:3.141.59)
Duplicate class org.openqa.selenium.WebDriver$ImeHandler found in modules java-client-7.0.0.jar (io.appium:java-client:7.0.0) and selenium-api-3.141.59.jar (org.seleniumhq.selenium:selenium-api:3.141.59)
Duplicate class org.openqa.selenium.WebDriver$Navigation found in modules java-client-7.0.0.jar (io.appium:java-client:7.0.0) and selenium-api-3.141.59.jar (org.seleniumhq.selenium:selenium-api:3.141.59)
Duplicate class org.openqa.selenium.WebDriver$Options found in modules java-client-7.0.0.jar (io.appium:java-client:7.0.0) and selenium-api-3.141.59.jar (org.seleniumhq.selenium:selenium-api:3.141.59)
Duplicate class org.openqa.selenium.WebDriver$TargetLocator found in modules java-client-7.0.0.jar (io.appium:java-client:7.0.0) and selenium-api-3.141.59.jar (org.seleniumhq.selenium:selenium-api:3.141.59)
Duplicate class org.openqa.selenium.WebDriver$Timeouts found in modules java-client-7.0.0.jar (io.appium:java-client:7.0.0) and selenium-api-3.141.59.jar (org.seleniumhq.selenium:selenium-api:3.141.59)
Duplicate class org.openqa.selenium.WebDriver$Window found in modules java-client-7.0.0.jar (io.appium:java-client:7.0.0) and selenium-api-3.141.59.jar (org.seleniumhq.selenium:selenium-api:3.141.59)
Duplicate class org.openqa.selenium.WebElement found in modules java-client-7.0.0.jar (io.appium:java-client:7.0.0) and selenium-api-3.141.59.jar (org.seleniumhq.selenium:selenium-api:3.141.59)
Duplicate class org.openqa.selenium.internal.FindsByClassName found in modules java-client-7.0.0.jar (io.appium:java-client:7.0.0) and selenium-api-3.141.59.jar (org.seleniumhq.selenium:selenium-api:3.141.59)
Duplicate class org.openqa.selenium.internal.FindsByCssSelector found in modules java-client-7.0.0.jar (io.appium:java-client:7.0.0) and selenium-api-3.141.59.jar (org.seleniumhq.selenium:selenium-api:3.141.59)
Duplicate class org.openqa.selenium.internal.FindsById found in modules java-client-7.0.0.jar (io.appium:java-client:7.0.0) and selenium-api-3.141.59.jar (org.seleniumhq.selenium:selenium-api:3.141.59)
Duplicate class org.openqa.selenium.internal.FindsByLinkText found in modules java-client-7.0.0.jar (io.appium:java-client:7.0.0) and selenium-api-3.141.59.jar (org.seleniumhq.selenium:selenium-api:3.141.59)
Duplicate class org.openqa.selenium.internal.FindsByName found in modules java-client-7.0.0.jar (io.appium:java-client:7.0.0) and selenium-api-3.141.59.jar (org.seleniumhq.selenium:selenium-api:3.141.59)
Duplicate class org.openqa.selenium.internal.FindsByTagName found in modules java-client-7.0.0.jar (io.appium:java-client:7.0.0) and selenium-api-3.141.59.jar (org.seleniumhq.selenium:selenium-api:3.141.59)
Duplicate class org.openqa.selenium.internal.FindsByXPath found in modules java-client-7.0.0.jar (io.appium:java-client:7.0.0) and selenium-api-3.141.59.jar (org.seleniumhq.selenium:selenium-api:3.141.59)

Go to the documentation to learn how to Fix dependency resolution errors.