[ 
https://issues.apache.org/jira/browse/BEAM-3713?focusedWorklogId=598278&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-598278
 ]

ASF GitHub Bot logged work on BEAM-3713:
----------------------------------------

                Author: ASF GitHub Bot
            Created on: 17/May/21 21:39
            Start Date: 17/May/21 21:39
    Worklog Time Spent: 10m 
      Work Description: udim commented on a change in pull request #14788:
URL: https://github.com/apache/beam/pull/14788#discussion_r633885729



##########
File path: sdks/python/test-suites/dataflow/common.gradle
##########
@@ -158,19 +168,47 @@ task validatesRunnerStreamingTests {
   def dataflowWorkerJar = 
project(":runners:google-cloud-dataflow-java:worker").shadowJar.archivePath
 
   // TODO(BEAM-3544,BEAM-5025): Disable tests with 'sickbay-streaming' tag.
-  def testOpts = basicTestOpts + ["--attr=ValidatesRunner,!sickbay-streaming"]
-  def argMap = ["test_opts": testOpts,
+  // Execute tests with xdists
+  doFirst {
+    def argMap = [
+                "test_opts": basicPytestOpts + ["--numprocesses=8"],
                 "streaming": "true",
                 "sdk_location": 
files(configurations.distTarBall.files).singleFile,
                 "worker_jar": dataflowWorkerJar,
-                "suite": 
"validatesRunnerStreamingTests-df${pythonVersionSuffix}"]
-  if (project.hasProperty('useRunnerV2')) {
-    argMap.put("runner_v2", "true")
-    // KMS is not supported for streaming engine.
-    argMap.put("kms_key_name", "\"\"")
+                "suite": 
"validatesRunnerStreamingTests-df${pythonVersionSuffix}-xdist",
+                "pytest": true, // TODO(BEAM-3713): Remove this once nose is 
removed
+                "collect": "it_validatesrunner and not no_sickbay_streaming"
+                ]
+    if (project.hasProperty('useRunnerV2')) {
+      argMap.put("runner_v2", "true")
+      // KMS is not supported for streaming engine.
+      argMap.put("kms_key_name", "\"\"")
+    }
+
+    def cmdArgs = mapToArgString(argMap)
+    exec {
+      executable 'sh'
+      args '-c', ". ${envdir}/bin/activate && 
${runScriptsDir}/run_integration_test.sh $cmdArgs"
+    }
   }
 
+  // Execute tests that fail with xdists
   doLast {
+    def tests = 
["apache_beam/runners/dataflow/dataflow_exercise_streaming_metrics_pipeline_test.py"]

Review comment:
       Please use the `no_xdist` marker instead (specified in "collect").
   
   The markers make it easier to understand where and how the test is run, 
since they are in one place.




-- 
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]


Issue Time Tracking
-------------------

    Worklog Id:     (was: 598278)
    Time Spent: 56h 40m  (was: 56.5h)

> Consider moving away from nose to nose2 or pytest.
> --------------------------------------------------
>
>                 Key: BEAM-3713
>                 URL: https://issues.apache.org/jira/browse/BEAM-3713
>             Project: Beam
>          Issue Type: Test
>          Components: sdk-py-core, testing
>            Reporter: Robert Bradshaw
>            Assignee: Benjamin Gonzalez
>            Priority: P3
>          Time Spent: 56h 40m
>  Remaining Estimate: 0h
>
> Per 
> [https://nose.readthedocs.io/en/latest/|https://nose.readthedocs.io/en/latest/,]
>  , nose is in maintenance mode.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to