Skip to content

Commit 29a2f71

Browse files
authored
Parametrize the JDK used for testing (#10)
Demonstrates using the [`parametrize` builtin](https://www.pantsbuild.org/v2.11/docs/targets#parametrizing-targets) with the [`jdk` field](https://www.pantsbuild.org/v2.11/docs/reference-scalatest_tests#codejdkcode), to run the same test under multiple JDKs.
1 parent 5981f0b commit 29a2f71

File tree

1 file changed

+5
-1
lines changed
  • tests/jvm/org/pantsbuild/example/lib

1 file changed

+5
-1
lines changed
Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,5 @@
1-
scalatest_tests()
1+
scalatest_tests(
2+
# These tests are `parametrize`d, so that they will run against two different
3+
# JDK versions.
4+
jdk=parametrize(adopt_11="adopt:1.11", adopt_12="adopt:1.12.0.2"),
5+
)

0 commit comments

Comments
 (0)