]> SALOME platform Git repositories - samples/hello.git/blobdiff - bin/test_hello.py
Salome HOME
Merge Python 3 porting.
[samples/hello.git] / bin / test_hello.py
index 6f15512547bded1231e744b4c830f8513bdebb60..94efb8d811a29f41e016b9b80ec706f5844bbdbe 100755 (executable)
@@ -30,28 +30,28 @@ import HELLO_ORB
 hello = salome.lcc.FindOrLoadComponent('FactoryServer', 'HELLO')
 
 # test HELLO module
-print "Say hello to John: should be OK"
+print("Say hello to John: should be OK")
 if hello.hello("John") != HELLO_ORB.OP_OK:
-    print "ERROR: wrong operation code is returned"
+    print("ERROR: wrong operation code is returned")
 else:
-    print "OK"
-print "Say hello to John: should answer 'already met'"
+    print("OK")
+print("Say hello to John: should answer 'already met'")
 if hello.hello("John") != HELLO_ORB.OP_ERR_ALREADY_MET:
-    print "ERROR: wrong operation code is returned"
+    print("ERROR: wrong operation code is returned")
 else:
-    print "OK"
-print "Say goodbye to Margaret: should answer 'did not meet yet'"
+    print("OK")
+print("Say goodbye to Margaret: should answer 'did not meet yet'")
 if hello.goodbye("Margaret") != HELLO_ORB.OP_ERR_DID_NOT_MEET:
-    print "ERROR: wrong operation code is returned"
+    print("ERROR: wrong operation code is returned")
 else:
-    print "OK"
-print "Say hello to John: should be OK"
+    print("OK")
+print("Say hello to John: should be OK")
 if hello.goodbye("John") != HELLO_ORB.OP_OK:
-    print "ERROR: wrong operation code is returned"
+    print("ERROR: wrong operation code is returned")
 else:
-    print "OK"
-print "Say hello to John: should answer 'did not meet yet'"
+    print("OK")
+print("Say hello to John: should answer 'did not meet yet'")
 if hello.goodbye("John") != HELLO_ORB.OP_ERR_DID_NOT_MEET:
-    print "ERROR: wrong operation code is returned"
+    print("ERROR: wrong operation code is returned")
 else:
-    print "OK"
+    print("OK")