This commit is needed since autotest tries to run AT_XFAIL_IF when
AT_SKIP_IF condition is true too.

Currently HAVE_PYTHON is required, but this may change in the future
since many distributions are migrating to python3 as default python
(like Arch Linux or Fedora) and so it can be a good idea to permit to
build OVS using python3.

Signed-off-by: Timothy Redaelli <tredae...@redhat.com>
---
 tests/json.at | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/tests/json.at b/tests/json.at
index ba7d4bbbe..325ac9435 100644
--- a/tests/json.at
+++ b/tests/json.at
@@ -26,7 +26,8 @@ m4_define([JSON_CHECK_POSITIVE_UCS4PY],
   [AT_SETUP([$1])
    AT_KEYWORDS([json positive Python])
    AT_SKIP_IF([test $HAVE_PYTHON = no])
-   AT_XFAIL_IF([$PYTHON -c "exit(len(u'\U00010800'))"; test $? -ne 1])
+   AT_XFAIL_IF([test $HAVE_PYTHON = yes &&
+                $PYTHON -c "exit(len(u'\U00010800'))"; test $? -ne 1])
    AT_CHECK([printf %s "AS_ESCAPE([$2])" > input])
    AT_CAPTURE_FILE([input])
    AT_CHECK([$PYTHON $srcdir/test-json.py $4 input], [0], [stdout], [])
-- 
2.14.3

_______________________________________________
dev mailing list
d...@openvswitch.org
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to