This is an automated email from the ASF dual-hosted git repository.

pabloem pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/beam.git


The following commit(s) were added to refs/heads/master by this push:
     new 2cf6a20  [BEAM-6621][BEAM-6624] add direct runner and dataflow runner 
it test suites for python 3.6
     new 9814ba9  Merge pull request #8381 from Juta/it-tests
2cf6a20 is described below

commit 2cf6a20de01c1ebdeb01b4688ff0a894faa209da
Author: Juta <[email protected]>
AuthorDate: Tue Apr 23 17:27:34 2019 +0200

    [BEAM-6621][BEAM-6624] add direct runner and dataflow runner it test suites 
for python 3.6
---
 build.gradle                                                 |  8 +++++---
 .../apache_beam/examples/complete/game/game_stats_it_test.py |  6 ++++++
 .../examples/complete/game/leader_board_it_test.py           |  6 ++++++
 .../apache_beam/examples/streaming_wordcount_it_test.py      |  6 ++++++
 sdks/python/apache_beam/examples/wordcount_it_test.py        |  6 ++++++
 sdks/python/apache_beam/io/gcp/pubsub_integration_test.py    | 10 ++++++++++
 .../dataflow/dataflow_exercise_metrics_pipeline_test.py      |  6 ++++++
 sdks/python/test-suites/dataflow/{py3 => py35}/build.gradle  |  0
 sdks/python/test-suites/dataflow/{py3 => py36}/build.gradle  |  3 +--
 sdks/python/test-suites/direct/{py3 => py35}/build.gradle    |  0
 sdks/python/test-suites/direct/{py3 => py36}/build.gradle    |  3 +--
 settings.gradle                                              | 12 ++++++++----
 12 files changed, 55 insertions(+), 11 deletions(-)

diff --git a/build.gradle b/build.gradle
index f890a38..7daea0d 100644
--- a/build.gradle
+++ b/build.gradle
@@ -198,9 +198,11 @@ task pythonPostCommit() {
 }
 
 task python3PostCommit() {
-  dependsOn ":beam-sdks-python-test-suites-dataflow-py3:postCommitIT"
-  dependsOn 
":beam-sdks-python-test-suites-dataflow-py3:validatesRunnerBatchTests"
-  dependsOn ":beam-sdks-python-test-suites-direct-py3:postCommitIT"
+  dependsOn ":beam-sdks-python-test-suites-dataflow-py35:postCommitIT"
+  dependsOn ":beam-sdks-python-test-suites-dataflow-py36:postCommitIT"
+  dependsOn 
":beam-sdks-python-test-suites-dataflow-py35:validatesRunnerBatchTests"
+  dependsOn ":beam-sdks-python-test-suites-direct-py35:postCommitIT"
+  dependsOn ":beam-sdks-python-test-suites-direct-py36:postCommitIT"
 }
 
 task portablePythonPreCommit() {
diff --git 
a/sdks/python/apache_beam/examples/complete/game/game_stats_it_test.py 
b/sdks/python/apache_beam/examples/complete/game/game_stats_it_test.py
index cba4b00..a2d1abf 100644
--- a/sdks/python/apache_beam/examples/complete/game/game_stats_it_test.py
+++ b/sdks/python/apache_beam/examples/complete/game/game_stats_it_test.py
@@ -33,6 +33,8 @@ Usage:
 from __future__ import absolute_import
 
 import logging
+import os
+import sys
 import time
 import unittest
 import uuid
@@ -103,6 +105,10 @@ class GameStatsIT(unittest.TestCase):
     test_utils.cleanup_subscriptions(self.sub_client, [self.input_sub])
     test_utils.cleanup_topics(self.pub_client, [self.input_topic])
 
+  @unittest.skipIf(sys.version[0:3] == '3.6' and
+                   os.environ.get('RUN_SKIPPED_PY3_TESTS') != '1',
+                   'This test still needs to be fixed on Python 3.6 '
+                   'TODO: BEAM-7182')
   @attr('IT')
   def test_game_stats_it(self):
     state_verifier = PipelineStateMatcher(PipelineState.RUNNING)
diff --git 
a/sdks/python/apache_beam/examples/complete/game/leader_board_it_test.py 
b/sdks/python/apache_beam/examples/complete/game/leader_board_it_test.py
index 9f057fd..c712352 100644
--- a/sdks/python/apache_beam/examples/complete/game/leader_board_it_test.py
+++ b/sdks/python/apache_beam/examples/complete/game/leader_board_it_test.py
@@ -33,6 +33,8 @@ Usage:
 from __future__ import absolute_import
 
 import logging
+import os
+import sys
 import time
 import unittest
 import uuid
@@ -105,6 +107,10 @@ class LeaderBoardIT(unittest.TestCase):
     test_utils.cleanup_subscriptions(self.sub_client, [self.input_sub])
     test_utils.cleanup_topics(self.pub_client, [self.input_topic])
 
+  @unittest.skipIf(sys.version[0:3] == '3.6' and
+                   os.environ.get('RUN_SKIPPED_PY3_TESTS') != '1',
+                   'This test still needs to be fixed on Python 3.6 '
+                   'TODO: BEAM-7182')
   @attr('IT')
   def test_leader_board_it(self):
     state_verifier = PipelineStateMatcher(PipelineState.RUNNING)
diff --git a/sdks/python/apache_beam/examples/streaming_wordcount_it_test.py 
b/sdks/python/apache_beam/examples/streaming_wordcount_it_test.py
index 281dc69..fabb773 100644
--- a/sdks/python/apache_beam/examples/streaming_wordcount_it_test.py
+++ b/sdks/python/apache_beam/examples/streaming_wordcount_it_test.py
@@ -20,6 +20,8 @@
 from __future__ import absolute_import
 
 import logging
+import os
+import sys
 import unittest
 import uuid
 from builtins import range
@@ -78,6 +80,10 @@ class StreamingWordCountIT(unittest.TestCase):
     test_utils.cleanup_topics(self.pub_client,
                               [self.input_topic, self.output_topic])
 
+  @unittest.skipIf(sys.version[0:3] == '3.6' and
+                   os.environ.get('RUN_SKIPPED_PY3_TESTS') != '1',
+                   'This test still needs to be fixed on Python 3.6 '
+                   'TODO: BEAM-7181')
   @attr('IT')
   def test_streaming_wordcount_it(self):
     # Build expected dataset.
diff --git a/sdks/python/apache_beam/examples/wordcount_it_test.py 
b/sdks/python/apache_beam/examples/wordcount_it_test.py
index eabe88b..868f837 100644
--- a/sdks/python/apache_beam/examples/wordcount_it_test.py
+++ b/sdks/python/apache_beam/examples/wordcount_it_test.py
@@ -20,6 +20,8 @@
 from __future__ import absolute_import
 
 import logging
+import os
+import sys
 import time
 import unittest
 
@@ -46,6 +48,10 @@ class WordCountIT(unittest.TestCase):
   def test_wordcount_it(self):
     self._run_wordcount_it(wordcount.run)
 
+  @unittest.skipIf(sys.version[0:3] == '3.6' and
+                   os.environ.get('RUN_SKIPPED_PY3_TESTS') != '1',
+                   'This test still needs to be fixed on Python 3.6 '
+                   'TODO: BEAM-7183')
   @attr('IT', 'ValidatesContainer')
   def test_wordcount_fnapi_it(self):
     self._run_wordcount_it(wordcount.run, experiment='beam_fn_api')
diff --git a/sdks/python/apache_beam/io/gcp/pubsub_integration_test.py 
b/sdks/python/apache_beam/io/gcp/pubsub_integration_test.py
index c8a743e..6d3549c 100644
--- a/sdks/python/apache_beam/io/gcp/pubsub_integration_test.py
+++ b/sdks/python/apache_beam/io/gcp/pubsub_integration_test.py
@@ -20,6 +20,8 @@ Integration test for Google Cloud Pub/Sub.
 from __future__ import absolute_import
 
 import logging
+import os
+import sys
 import unittest
 import uuid
 
@@ -170,10 +172,18 @@ class PubSubIntegrationTest(unittest.TestCase):
         id_label=self.ID_LABEL,
         timestamp_attribute=self.TIMESTAMP_ATTRIBUTE)
 
+  @unittest.skipIf(sys.version[0:3] == '3.6' and
+                   os.environ.get('RUN_SKIPPED_PY3_TESTS') != '1',
+                   'This test still needs to be fixed on Python 3.6 '
+                   'TODO: BEAM-7181')
   @attr('IT')
   def test_streaming_data_only(self):
     self._test_streaming(with_attributes=False)
 
+  @unittest.skipIf(sys.version[0:3] == '3.6' and
+                   os.environ.get('RUN_SKIPPED_PY3_TESTS') != '1',
+                   'This test still needs to be fixed on Python 3.6 '
+                   'TODO: BEAM-7181')
   @attr('IT')
   def test_streaming_with_attributes(self):
     self._test_streaming(with_attributes=True)
diff --git 
a/sdks/python/apache_beam/runners/dataflow/dataflow_exercise_metrics_pipeline_test.py
 
b/sdks/python/apache_beam/runners/dataflow/dataflow_exercise_metrics_pipeline_test.py
index c62824d..620f83c 100644
--- 
a/sdks/python/apache_beam/runners/dataflow/dataflow_exercise_metrics_pipeline_test.py
+++ 
b/sdks/python/apache_beam/runners/dataflow/dataflow_exercise_metrics_pipeline_test.py
@@ -20,6 +20,8 @@
 from __future__ import absolute_import
 
 import argparse
+import os
+import sys
 import unittest
 
 from nose.plugins.attrib import attr
@@ -55,6 +57,10 @@ class ExerciseMetricsPipelineTest(unittest.TestCase):
         dataflow_exercise_metrics_pipeline.legacy_metric_matchers())
     self.assertFalse(errors, str(errors))
 
+  @unittest.skipIf(sys.version[0:3] == '3.6' and
+                   os.environ.get('RUN_SKIPPED_PY3_TESTS') != '1',
+                   'This test still needs to be fixed on Python 3.6 '
+                   'TODO: BEAM-7183')
   @attr('IT', 'ValidatesContainer')
   def test_metrics_fnapi_it(self):
     result = self.run_pipeline(experiment='beam_fn_api')
diff --git a/sdks/python/test-suites/dataflow/py3/build.gradle 
b/sdks/python/test-suites/dataflow/py35/build.gradle
similarity index 100%
copy from sdks/python/test-suites/dataflow/py3/build.gradle
copy to sdks/python/test-suites/dataflow/py35/build.gradle
diff --git a/sdks/python/test-suites/dataflow/py3/build.gradle 
b/sdks/python/test-suites/dataflow/py36/build.gradle
similarity index 98%
rename from sdks/python/test-suites/dataflow/py3/build.gradle
rename to sdks/python/test-suites/dataflow/py36/build.gradle
index 7d31cb3..b685d05 100644
--- a/sdks/python/test-suites/dataflow/py3/build.gradle
+++ b/sdks/python/test-suites/dataflow/py36/build.gradle
@@ -18,10 +18,9 @@
 
 apply plugin: org.apache.beam.gradle.BeamModulePlugin
 applyPythonNature()
-enablePythonPerformanceTest()
 
 // Required to setup a Python 3 virtualenv.
-pythonVersion = '3.5'
+pythonVersion = '3.6'
 
 def runScriptsDir = "${project.rootDir}/sdks/python/scripts"
 
diff --git a/sdks/python/test-suites/direct/py3/build.gradle 
b/sdks/python/test-suites/direct/py35/build.gradle
similarity index 100%
copy from sdks/python/test-suites/direct/py3/build.gradle
copy to sdks/python/test-suites/direct/py35/build.gradle
diff --git a/sdks/python/test-suites/direct/py3/build.gradle 
b/sdks/python/test-suites/direct/py36/build.gradle
similarity index 95%
rename from sdks/python/test-suites/direct/py3/build.gradle
rename to sdks/python/test-suites/direct/py36/build.gradle
index 56b77a3..cc55c5a 100644
--- a/sdks/python/test-suites/direct/py3/build.gradle
+++ b/sdks/python/test-suites/direct/py36/build.gradle
@@ -20,7 +20,7 @@ plugins { id 'org.apache.beam.module' }
 applyPythonNature()
 
 // Required to setup a Python 3 virtualenv.
-pythonVersion = '3.5'
+pythonVersion = '3.6'
 
 def runScriptsDir = "${project.rootDir}/sdks/python/scripts"
 
@@ -32,7 +32,6 @@ task postCommitIT(dependsOn: 'installGcpTest') {
         "apache_beam.io.gcp.pubsub_integration_test:PubSubIntegrationTest",
         
"apache_beam.io.gcp.big_query_query_to_table_it_test:BigQueryQueryToTableIT",
         "apache_beam.io.gcp.bigquery_io_read_it_test",
-        "apache_beam.io.gcp.datastore.v1new.datastore_write_it_test",
     ]
     def testOpts = [
         "--tests=${batchTests.join(',')}",
diff --git a/settings.gradle b/settings.gradle
index 5d2dfc8..ab18dd9 100644
--- a/settings.gradle
+++ b/settings.gradle
@@ -213,10 +213,14 @@ include "beam-sdks-python-container-py3"
 project(":beam-sdks-python-container-py3").dir = 
file("sdks/python/container/py3")
 include "beam-sdks-python-test-suites-dataflow"
 project(":beam-sdks-python-test-suites-dataflow").dir = 
file("sdks/python/test-suites/dataflow")
-include "beam-sdks-python-test-suites-dataflow-py3"
-project(":beam-sdks-python-test-suites-dataflow-py3").dir = 
file("sdks/python/test-suites/dataflow/py3")
-include "beam-sdks-python-test-suites-direct-py3"
-project(":beam-sdks-python-test-suites-direct-py3").dir = 
file("sdks/python/test-suites/direct/py3")
+include "beam-sdks-python-test-suites-dataflow-py35"
+project(":beam-sdks-python-test-suites-dataflow-py35").dir = 
file("sdks/python/test-suites/dataflow/py35")
+include "beam-sdks-python-test-suites-dataflow-py36"
+project(":beam-sdks-python-test-suites-dataflow-py36").dir = 
file("sdks/python/test-suites/dataflow/py36")
+include "beam-sdks-python-test-suites-direct-py35"
+project(":beam-sdks-python-test-suites-direct-py35").dir = 
file("sdks/python/test-suites/direct/py35")
+include "beam-sdks-python-test-suites-direct-py36"
+project(":beam-sdks-python-test-suites-direct-py36").dir = 
file("sdks/python/test-suites/direct/py36")
 include "beam-sdks-python-test-suites-tox-py35"
 project(":beam-sdks-python-test-suites-tox-py35").dir = 
file("sdks/python/test-suites/tox/py35")
 include "beam-sdks-python-test-suites-tox-py36"

Reply via email to