From 598e487971f019f2f081a3fc33e14875e4ae8f03 Mon Sep 17 00:00:00 2001 From: Till Maas Date: Fri, 25 May 2018 19:51:09 +0200 Subject: [PATCH] Only run tests with python2 or python3 binary Also fail, when the tests did not run with at least one of them. --- tests/tests_unit.yml | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/tests/tests_unit.yml b/tests/tests_unit.yml index d9d60d0..203b98b 100644 --- a/tests/tests_unit.yml +++ b/tests/tests_unit.yml @@ -52,9 +52,6 @@ when: python3_available is succeeded register: python3_result - - command: python /tmp/test-unit-1/test_network_connections.py --verbose - register: python_result - - debug: var: python2_result.stderr_lines when: python2_result is succeeded @@ -63,6 +60,6 @@ var: python3_result.stderr_lines when: python3_result is succeeded - - debug: - var: python_result.stderr_lines - when: python_result is succeeded + - fail: + msg: Tests did not run with python2 or python3 + when: not (python2_available is succeeded or python3_available is succeeded)