Downloads JAR then fails to resolve -- what?

I’m a Gradle beginner getting some confusing error messages from the build. Gradle 2.7 appears to find and download the dependency but then the build fails, complaining it cannot resolve the JAR file it just downloaded (and which is now in the Gradle cache). It’s not surprising that it can’t resolve the dependency it cites, since the name has been mangled (note the addition of the version number twice). What is going on here?

The build file:

    plugins {
      id 'groovy'
    }
    
    apply plugin: 'groovy'
    
    repositories {
      mavenCentral()
      maven {                                   // BioPAX Releases
        url "http://biopax.sourceforge.net/m2repo/releases"
      }
      maven {                                   // BioPAX Snapshots
        url "http://biopax.sourceforge.net/m2repo/snapshots"
      }
      mavenLocal()
    }
    
    configurations.all {
      resolutionStrategy {
        force 'xml-apis:xml-apis:1.4.01'
      }
    }

dependencies {
  compile 'org.codehaus.groovy:groovy-all:2.4.4'
  ...
  compile 'edu.stanford.nlp:stanford-corenlp:3.5.1'
  compile 'edu.stanford.nlp:stanford-corenlp:models:3.5.1'

The error output:

Download https://repo1.maven.org/maven2/edu/stanford/nlp/stanford-corenlp/3.5.1/stanford-corenlp-3.5.1.jar

FAILURE: Build failed with an exception.

  • What went wrong:
    Could not resolve all dependencies for configuration ‘:testCompile’.

Could not find stanford-corenlp-3.5.1.jar (edu.stanford.nlp:stanford-corenlp:3.5.1).
Searched in the following locations:
https://repo1.maven.org/maven2/edu/stanford/nlp/stanford-corenlp/3.5.1/stanford-corenlp-3.5.1-3.5.1.jar