Migrate cvp-sanity to Python3
* use print function from future
* convert dict keys and values to list
* do not use bunch imports
* fix requirements mismatch
Related: PROD-33849
Change-Id: Ifecc3a9dcdcfe3243f7dcf2c709a80e9a7c765a1
(cherry picked from commit e32e3f9ea37a24da5365dcef2a13609057b61923)
diff --git a/test_set/cvp-sanity/tests/test_etc_hosts.py b/test_set/cvp-sanity/tests/test_etc_hosts.py
index bf881e7..12378f1 100644
--- a/test_set/cvp-sanity/tests/test_etc_hosts.py
+++ b/test_set/cvp-sanity/tests/test_etc_hosts.py
@@ -9,11 +9,11 @@
param='cat /etc/hosts',
expr_form='compound')
result = {}
- for node in nodes_info.keys():
+ for node in list(nodes_info.keys()):
if isinstance(nodes_info[node], bool):
result[node] = 'Cannot access this node'
continue
- for nd in nodes_info.keys():
+ for nd in list(nodes_info.keys()):
if nd not in nodes_info[node]:
if node in result:
result[node] += ',' + nd