kennknowles commented on a change in pull request #12981:
URL: https://github.com/apache/beam/pull/12981#discussion_r497855759



##########
File path: runners/portability/java/build.gradle
##########
@@ -108,95 +120,113 @@ startLocalJobService.finalizedBy stopLocalJobService
 
 /**
  * Runs Java ValidatesRunner tests against the Universal Local Runner (ULR) 
aka local_job_service_main
- * with subprocess SDK harness environments.
+ * with the specified environment type.
  */
-task ulrValidatesRunnerTests(type: Test) {
-  dependsOn ":sdks:java:container:docker"
-
-  if (!project.hasProperty("localJobServicePortFile")) {
-    dependsOn startLocalJobService
+def createUlrValidatesRunnerTask = { name, environmentType ->
+  Task vrTask = tasks.create(name: name, type: Test, group: "Verification") {
+    description "PortableRunner Java docker ValidatesRunner suite"
+    classpath = configurations.validatesRunner
+    systemProperty "beamTestPipelineOptions", JsonOutput.toJson([
+        "--runner=TestUniversalRunner",
+        "--experiments=beam_fn_api",
+        "--defaultEnvironmentType=${environmentType}",
+        "--localJobServicePortFile=${localJobServicePortFile}"
+    ])
+    testClassesDirs = 
files(project(":sdks:java:core").sourceSets.test.output.classesDirs)
+    useJUnit {
+      includeCategories 'org.apache.beam.sdk.testing.ValidatesRunner'
+      excludeCategories 'org.apache.beam.sdk.testing.UsesGaugeMetrics'
+      excludeCategories 'org.apache.beam.sdk.testing.UsesOnWindowExpiration'
+      excludeCategories 'org.apache.beam.sdk.testing.UsesBundleFinalizer'

Review comment:
       I don't believe so. I think all excluded categories are essentially 
feature enhancements for the roadmap. For individual test cases that do not 
correspond to a category they each have a Jira, since we should aim to support 
features entirely or not at all. We should also avoid adding fine-grained 
categories if they do not correspond to real general concepts.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to