Change `coverage_config.runner` to type `JavaInfo`
In bazel, the toolchain only has reference to a `File`, and not a `Target`. We wrap this `File` in a `JavaInfo` so it can be added to deps.
@@ -103,7 +103,7 @@ def basic_java_library(
javacopts: (list[str])
neverlink: (bool) Whether this library should only be used for compilation and not at runtime.
enable_compile_jar_action: (bool) Enables header compilation or ijar creation.
- coverage_config: (struct{runner:Target, support_files:list[File]|depset[File], env:dict[str,str]})
+ coverage_config: (struct{runner:JavaInfo, support_files:list[File]|depset[File], env:dict[str,str]})
Coverage configuration. `runner` is added to dependencies during
compilation, `support_files` and `env` is returned in InstrumentedFilesInfo.
proguard_specs: (list[File]) Files to be used as Proguard specification.
@@ -133,7 +133,7 @@ def basic_java_library(
ctx.outputs.sourcejar,
source_files,
source_jars,
- collect_deps(deps + [coverage_config.runner]) if coverage_config and coverage_config.runner else collect_deps(deps),
+ collect_deps(deps) + ([coverage_config.runner] if coverage_config and coverage_config.runner else []),
collect_deps(runtime_deps),
plugins_javaplugininfo,
collect_deps(exports),
