Author: tomwhite
Date: Wed Dec 16 14:21:56 2015
New Revision: 1720361

URL: http://svn.apache.org/viewvc?rev=1720361&view=rev
Log:
Add sleep statement to Python tests to avoid race condition.

Modified:
    avro/branches/branch-1.8/lang/py/test/test_tether_task_runner.py
    avro/branches/branch-1.8/lang/py/test/test_tether_word_count.py

Modified: avro/branches/branch-1.8/lang/py/test/test_tether_task_runner.py
URL: 
http://svn.apache.org/viewvc/avro/branches/branch-1.8/lang/py/test/test_tether_task_runner.py?rev=1720361&r1=1720360&r2=1720361&view=diff
==============================================================================
--- avro/branches/branch-1.8/lang/py/test/test_tether_task_runner.py (original)
+++ avro/branches/branch-1.8/lang/py/test/test_tether_task_runner.py Wed Dec 16 
14:21:56 2015
@@ -59,6 +59,9 @@ class TestTetherTaskRunner(unittest.Test
 
       runner.start(outputport=parent_port,join=False)
 
+      # Wait for the server to start
+      time.sleep(1)
+
       # Test sending various messages to the server and ensuring they are
       # processed correctly
       
requestor=HTTPRequestor("localhost",runner.server.server_address[1],inputProtocol)

Modified: avro/branches/branch-1.8/lang/py/test/test_tether_word_count.py
URL: 
http://svn.apache.org/viewvc/avro/branches/branch-1.8/lang/py/test/test_tether_word_count.py?rev=1720361&r1=1720360&r2=1720361&view=diff
==============================================================================
--- avro/branches/branch-1.8/lang/py/test/test_tether_word_count.py (original)
+++ avro/branches/branch-1.8/lang/py/test/test_tether_word_count.py Wed Dec 16 
14:21:56 2015
@@ -189,6 +189,7 @@ python -m avro.tether.tether_task_runner
 
 
       proc.wait()
+      time.sleep(1) # wait a bit longer to clean up
 
       # read the output
       with file(os.path.join(outpath,"part-00000.avro")) as hf:


Reply via email to