Sergiusz Bazanski | 57efce6 | 2019-07-21 16:39:54 +0200 | [diff] [blame] | 1 | load("//devtools/gerrit/gerrit-oauth-provider/tools/bzl:junit.bzl", "junit_tests") |
Sergiusz Bazanski | 573da78 | 2019-06-21 19:59:52 +0200 | [diff] [blame] | 2 | load( |
Sergiusz Bazanski | 57efce6 | 2019-07-21 16:39:54 +0200 | [diff] [blame] | 3 | "//devtools/gerrit/gerrit-oauth-provider/tools/bzl:plugin.bzl", |
Sergiusz Bazanski | 573da78 | 2019-06-21 19:59:52 +0200 | [diff] [blame] | 4 | "PLUGIN_DEPS", |
| 5 | "PLUGIN_TEST_DEPS", |
| 6 | "gerrit_plugin", |
| 7 | ) |
| 8 | |
| 9 | gerrit_plugin( |
| 10 | name = "gerrit-oauth-provider", |
| 11 | srcs = glob(["src/main/java/**/*.java"]), |
| 12 | manifest_entries = [ |
| 13 | "Gerrit-PluginName: gerrit-oauth-provider", |
| 14 | "Gerrit-HttpModule: com.googlesource.gerrit.plugins.oauth.HttpModule", |
| 15 | "Gerrit-InitStep: com.googlesource.gerrit.plugins.oauth.InitOAuth", |
| 16 | "Implementation-Title: Gerrit OAuth authentication provider", |
| 17 | "Implementation-URL: https://github.com/davido/gerrit-oauth-provider", |
| 18 | ], |
| 19 | resources = glob(["src/main/resources/**/*"]), |
| 20 | deps = [ |
| 21 | "@commons-codec//jar:neverlink", |
| 22 | "@scribe//jar", |
| 23 | ], |
| 24 | ) |
| 25 | |
| 26 | junit_tests( |
| 27 | name = "gerrit-oauth-provider_tests", |
| 28 | srcs = glob(["src/test/java/**/*.java"]), |
| 29 | tags = ["oauth"], |
| 30 | deps = [ |
| 31 | ":gerrit-oauth-provider__plugin_test_deps", |
| 32 | ], |
| 33 | ) |
| 34 | |
| 35 | java_library( |
| 36 | name = "gerrit-oauth-provider__plugin_test_deps", |
| 37 | testonly = 1, |
| 38 | visibility = ["//visibility:public"], |
| 39 | exports = PLUGIN_DEPS + PLUGIN_TEST_DEPS + [ |
| 40 | ":gerrit-oauth-provider__plugin", |
| 41 | "@scribe//jar", |
| 42 | ], |
| 43 | ) |