Merge "Add docker build for escalator"
[releng.git] / utils / test / testapi / htmlize / htmlize.py
index 68d02fe..70976d2 100644 (file)
@@ -28,7 +28,10 @@ def main(args):
     # Generating html page
     cmd = 'java -jar swagger-codegen-cli.jar generate \
         -i specs.json -l html2 -o %s' % (args.output_directory)
-    os.system(cmd)
+    if os.system(cmd) == 0:
+        exit(0)
+    else:
+        exit(1)
 
 if __name__ == '__main__':
     parser = argparse.ArgumentParser(description='Create \
@@ -36,12 +39,12 @@ if __name__ == '__main__':
     parser.add_argument('-ru', '--resource-listing-url',
                         type=str,
                         required=False,
-                        default='http://localhost:8000/swagger/spec.json',
+                        default='http://testresults.opnfv.org/auto/swagger/spec.json',
                         help='Resource Listing Spec File')
     parser.add_argument('-au', '--api-declaration-url',
                         type=str,
                         required=False,
-                        default='http://localhost:8000/swagger/spec',
+                        default='http://testresults.opnfv.org/auto/swagger/spec',
                         help='API Declaration Spec File')
     parser.add_argument('-o', '--output-directory',
                         required=True,