summaryrefslogtreecommitdiffstats
path: root/ipatests/test_ipalib/test_rpc.py
diff options
context:
space:
mode:
authorPetr Viktorin <pviktori@redhat.com>2015-08-12 13:44:11 +0200
committerJan Cholasta <jcholast@redhat.com>2015-09-01 11:42:01 +0200
commit8de13bd7dd76f5f5b23d6e4fb84be1a2f1dc5c5e (patch)
treeac6435b79d3e540e907bcc88e3b1c534c2945626 /ipatests/test_ipalib/test_rpc.py
parentfb7943dab454f358316160b4baf99075603a162d (diff)
downloadfreeipa-8de13bd7dd76f5f5b23d6e4fb84be1a2f1dc5c5e.tar.gz
freeipa-8de13bd7dd76f5f5b23d6e4fb84be1a2f1dc5c5e.tar.xz
freeipa-8de13bd7dd76f5f5b23d6e4fb84be1a2f1dc5c5e.zip
Use the print function
In Python 3, `print` is no longer a statement. Call it as a function everywhere, and include the future import to remove the statement in Python 2 code as well. Reviewed-By: Christian Heimes <cheimes@redhat.com> Reviewed-By: Jan Cholasta <jcholast@redhat.com>
Diffstat (limited to 'ipatests/test_ipalib/test_rpc.py')
-rw-r--r--ipatests/test_ipalib/test_rpc.py11
1 files changed, 6 insertions, 5 deletions
diff --git a/ipatests/test_ipalib/test_rpc.py b/ipatests/test_ipalib/test_rpc.py
index dd24d055c..5c130bdc6 100644
--- a/ipatests/test_ipalib/test_rpc.py
+++ b/ipatests/test_ipalib/test_rpc.py
@@ -20,6 +20,7 @@
"""
Test the `ipalib.rpc` module.
"""
+from __future__ import print_function
from xmlrpclib import Binary, Fault, dumps, loads
@@ -275,7 +276,7 @@ class test_xml_introspection(object):
try:
result = api.Backend.xmlclient.conn.system.listMethods('foo')
except Fault as f:
- print f
+ print(f)
assert f.faultCode == 3003
assert f.faultString == (
"command 'system.listMethods' takes no arguments")
@@ -295,7 +296,7 @@ class test_xml_introspection(object):
try:
result = api.Backend.xmlclient.conn.system.methodSignature()
except Fault as f:
- print f
+ print(f)
assert f.faultCode == 3007
assert f.faultString == "'method name' is required"
else:
@@ -305,7 +306,7 @@ class test_xml_introspection(object):
try:
result = api.Backend.xmlclient.conn.system.methodSignature('a', 'b')
except Fault as f:
- print f
+ print(f)
assert f.faultCode == 3004
assert f.faultString == (
"command 'system.methodSignature' takes at most 1 argument")
@@ -316,7 +317,7 @@ class test_xml_introspection(object):
try:
result = api.Backend.xmlclient.conn.system.methodHelp()
except Fault as f:
- print f
+ print(f)
assert f.faultCode == 3007
assert f.faultString == "'method name' is required"
else:
@@ -326,7 +327,7 @@ class test_xml_introspection(object):
try:
result = api.Backend.xmlclient.conn.system.methodHelp('a', 'b')
except Fault as f:
- print f
+ print(f)
assert f.faultCode == 3004
assert f.faultString == (
"command 'system.methodHelp' takes at most 1 argument")