Skip to content

Commit

Permalink
[ros2topic] Add test timeout for tests using subprocess (#374)
Browse files Browse the repository at this point in the history
In case a subprocess hangs, then we are not waiting forever.

Signed-off-by: Jacob Perron <jacob@openrobotics.org>
  • Loading branch information
jacobperron authored Oct 22, 2019
1 parent c41da46 commit 1450f9c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions ros2topic/test/test_echo_pub.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ def echo_pub_node():


@pytest.mark.skipif(os.name == 'nt', reason='Subprocess bug in Windows Python 3.7.4')
@pytest.mark.timeout(60)
@pytest.mark.parametrize(
'topic,provide_qos,compatible_qos', [
('/clitest/topic/pub_basic', False, True),
Expand Down Expand Up @@ -123,6 +124,7 @@ def message_callback(msg):


@pytest.mark.skipif(os.name == 'nt', reason='Subprocess bug in Windows Python 3.7.4')
@pytest.mark.timeout(60)
@pytest.mark.parametrize(
'topic,provide_qos,compatible_qos', [
('/clitest/topic/echo_basic', False, True),
Expand Down

0 comments on commit 1450f9c

Please sign in to comment.