Modify test scripts of F version and add instructions about it
[vfc/nfvo/lcm.git] / resources / testscripts / F-version / ns / ns_upload.py
index f91c80b..d4e435b 100644 (file)
@@ -1,6 +1,10 @@
 import requests
+import sys
+from testscripts.const import MSB_BASE_URL, NS_CSAR_PATH
+
+id = sys.argv[1]
 
 requests.packages.urllib3.disable_warnings()
-url = 'https://192.168.235.89:30283/api/nsd/v1/ns_descriptors/84090010-6e67-4536-81cc-61ae7b0b4ecd/nsd_content'
-resp = requests.put(url, files={'file': open(r"C:\Users\86187\Desktop\vfc-tests\ns\ns-new\ns_vgw.csar", 'rb')}, verify=False)
+url = MSB_BASE_URL + '/api/nsd/v1/ns_descriptors/ + id /nsd_content'
+resp = requests.put(url, files={'file': open(NS_CSAR_PATH, 'rb')}, verify=False)
 print(resp.status_code)