From 00671cf9cfbcd9ed25d79712bf01d29cb8787bf2 Mon Sep 17 00:00:00 2001 From: Paul Vinciguerra Date: Sun, 25 Nov 2018 12:47:04 -0800 Subject: VPP-1508 python3 tests: python3 repr. Use six.reprlib. Uses repr for python 2 and reprlib for python 3. Change-Id: Ia343a492d533bd511ed57166381e10a37e452d36 Signed-off-by: Paul Vinciguerra --- test/vpp_object.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'test/vpp_object.py') diff --git a/test/vpp_object.py b/test/vpp_object.py index 088cc39ce0a..8fe549e74ff 100644 --- a/test/vpp_object.py +++ b/test/vpp_object.py @@ -2,6 +2,8 @@ from abc import ABCMeta, abstractmethod +import six + class VppObject(object): """ Abstract vpp object """ @@ -81,6 +83,6 @@ class VppObjectRegistry(object): if failed: logger.error("REG: Couldn't remove configuration for object(s):") for obj in failed: - logger.error(repr(obj)) + logger.error(six.reprlib(obj)) raise Exception("Couldn't remove configuration for object(s): %s" % (", ".join(str(x) for x in failed))) -- cgit 1.2.3-korg