Code Review
/
nonrtric.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Fetch of authorization token
[nonrtric.git]
/
test
/
common
/
extract_sdnc_reply.py
diff --git
a/test/common/extract_sdnc_reply.py
b/test/common/extract_sdnc_reply.py
index
9158edc
..
5e37aa2
100644
(file)
--- a/
test/common/extract_sdnc_reply.py
+++ b/
test/common/extract_sdnc_reply.py
@@
-20,12
+20,12
@@
import json
import sys
# Extract the response code and optional response message body from and SDNC A1 Controller API reply
import sys
# Extract the response code and optional response message body from and SDNC A1 Controller API reply
-
+# Args: <json-output-key> <file-containing-the response>
try:
try:
- with open(sys.argv[
1
]) as json_file:
+ with open(sys.argv[
2
]) as json_file:
reply = json.load(json_file)
reply = json.load(json_file)
- output=reply[
'output'
]
+ output=reply[
sys.argv[1]
]
status=str(output['http-status'])
while(len(status) < 3):
status="0"+status
status=str(output['http-status'])
while(len(status) < 3):
status="0"+status