summaryrefslogtreecommitdiff
blob: 3fd67591c09893dc40e1b4fccb9be7c060173942 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
--- a/scripts/endpoints_checker.py	(original)
+++ b/scripts/endpoints_checker.py	(refactored)
@@ -64,8 +64,8 @@
     strippedContent = RemoveCPPComments(content);
     match = ScanContent(strippedContent);
     if match:
-        print inputFile;
-        print "..." + strippedContent[match.start() : match.end()] + "...";
+        print(inputFile);
+        print("..." + strippedContent[match.start() : match.end()] + "...");
         return True;
 
     return False;
@@ -109,7 +109,7 @@
 assert ScanContent("\"cn-north-2 doesn't exist\"") == None;
 
 ###################Test End######################################
-print "Start checking hard coded endpoints in source files...";
+print("Start checking hard coded endpoints in source files...");
 exitCode = 0;
 RootDir = os.path.dirname(os.path.dirname(os.path.realpath(__file__)));
 for root, dirnames, fileNames in os.walk(RootDir):
@@ -117,5 +117,5 @@
         if fileName.endswith(('.h', '.cpp')):
             targetFile = os.path.join(root, fileName);
             exitCode |= CheckFile(targetFile);
-print "Finished checking hard coded endpoints in source files with exit code",exitCode,".";
+print("Finished checking hard coded endpoints in source files with exit code",exitCode,".");
 exit(exitCode);