Github user tdas commented on a diff in the pull request: https://github.com/apache/spark/pull/12673#discussion_r61311926 --- Diff: python/pyspark/sql/tests.py --- @@ -990,6 +996,31 @@ def test_stream_await_termination(self): cq.stop() shutil.rmtree(tmpPath) + def test_query_manager_await_termination(self): + df = self.sqlCtx.read.format('text').stream('python/test_support/sql/streaming') + for cq in self.sqlCtx.streams.active: + cq.stop() + tmpPath = tempfile.mkdtemp() + shutil.rmtree(tmpPath) + self.assertTrue(df.isStreaming) + out = os.path.join(tmpPath, 'out') + chk = os.path.join(tmpPath, 'chk') + cq = df.write.startStream(path=out, format='parquet', queryName='this_query', + checkpointLocation=chk) + self.assertTrue(cq.isActive) + try: + self.sqlCtx.streams.awaitAnyTermination("hello") + self.fail("Expected a value exception") + except ValueError: + pass + now = time.time() + res = self.sqlCtx.streams.awaitAnyTermination(2600) # test should take at least 2 seconds --- End diff -- this test is doing 2600 seconds??
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org