rules_jvm icon indicating copy to clipboard operation
rules_jvm copied to clipboard

Contributed Bazel rules that make working with java projects more pleasant

Results 50 rules_jvm issues
Sort by recently updated
recently updated
newest added

Sorry if this is the wrong place, but it's sometime hard to guess where the responsibility for certain functionality sits. I've written a set of unit tests in my bazel...

With a [ParameterizedTest](https://junit.org/junit5/docs/5.0.2/api/org/junit/jupiter/params/ParameterizedTest.html) it is possible to generate test case names with invalid XML characters. E.g. ``` @ParameterizedTest @ValueSource(strings = {"Weird\bname"}) void testFoo(String input) { ... } ``` The test...

Previously if there was an existing plugins attribute, and an additional plugin was added, the old value would get preserved rather than merged.

All tests generated by [@ParametrizedTest](https://junit.org/junit5/docs/current/user-guide/#writing-tests-parameterized-tests) are executed in the single shard. A simple example is available in the [repo](https://github.com/al-babych-fivetran/shard-example). It has a parametrized test with 20 values: ``` @ParameterizedTest @ValueSource(ints...

I am recently working on migrating a project from Maven to Bazel. As part of this, it has most modules which use junit4, but some which use junit5, and this...

I removed some test coverage in https://github.com/bazel-contrib/rules_jvm/pull/272, we should add it back.

rules_jvm updates the srcs attribute with the OS-specific path separator, which leads to unnecessary updates and the parent path being incorrectly trimmed, e.g. for the following project structure ``` ....

It seems that the `BazelJUnitOutputListener` class can handle only up to 4 jupiter `@Nested` classes for simple tests. This is because with no nesting, there are 3 segments, and since...

I have a use case to use `SuiteLauncherDiscoveryRequestBuilder` instead of `LauncherDiscoveryRequestBuilder`. Refactoring the runner to allow extending Junit5Runner and ActualRunner to enable extending the runner to allow for that.

Runner for JUnit 5 tests `java/src/com/github/bazel_contrib/contrib_rules_jvm/junit5/ActualRunner.java` ([source](https://github.com/bazel-contrib/rules_jvm/blob/main/java/src/com/github/bazel_contrib/contrib_rules_jvm/junit5/ActualRunner.java)) contains the following lines: ```java ... LauncherDiscoveryRequestBuilder request = LauncherDiscoveryRequestBuilder.request() .selectors(classSelectors) .configurationParameter(LauncherConstants.CAPTURE_STDERR_PROPERTY_NAME, "true") .configurationParameter(LauncherConstants.CAPTURE_STDOUT_PROPERTY_NAME, "true") .configurationParameter( Constants.EXTENSIONS_AUTODETECTION_ENABLED_PROPERTY_NAME, "true"); ... ``` Unfortunately, it's impossible...