apply from: "$rootDir/gradle/instrumentation.gradle"

muzzle {
  pass {
    group = "io.netty"
    module = "netty-codec-http"
    versions = "[4.1.0.Final,5.0.0)"
    assertInverse = true
  }
  pass {
    group = "io.netty"
    module = "netty-all"
    versions = "[4.1.0.Final,5.0.0)"
    assertInverse = true
  }
  fail {
    group = "io.netty"
    module = "netty"
    versions = "[,]"
  }
  pass {
    group = "io.vertx"
    module = "vertx-core"
    versions = "[3.3.0,)"
    assertInverse = true
  }
}

dependencies {
  library group: 'io.netty', name: 'netty-codec-http', version: '4.1.0.Final'
  api project(':instrumentation:netty:netty-4.1:library')

  //Contains logging handler
  testLibrary group: 'io.netty', name: 'netty-handler', version: '4.1.0.Final'

  latestDepTestLibrary group: 'io.netty', name: 'netty-codec-http', version: '(,5.0)'
  latestDepTestLibrary group: 'io.netty', name: 'netty-handler', version: '(,5.0)'
}

test {
  systemProperty "testLatestDeps", testLatestDeps
}
