mirror of
				https://github.com/Telecominfraproject/wlan-cloud-analytics.git
				synced 2025-10-31 02:17:47 +00:00 
			
		
		
		
	[WIFI-9772] Chg: fix test scripts to make requests to owanalytics instead of owprov
Signed-off-by: Dmitry Dunaev <dmitry@opsfleet.com>
This commit is contained in:
		
							
								
								
									
										1
									
								
								.gitignore
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										1
									
								
								.gitignore
									
									
									
									
										vendored
									
									
								
							| @@ -32,6 +32,7 @@ | |||||||
| *.app | *.app | ||||||
|  |  | ||||||
| test_scripts/curl/token.json | test_scripts/curl/token.json | ||||||
|  | test_scripts/curl/result.json | ||||||
| .vscode/c_cpp_properties.json | .vscode/c_cpp_properties.json | ||||||
| test_scripts/curl/result.json | test_scripts/curl/result.json | ||||||
| *.swp | *.swp | ||||||
|   | |||||||
| @@ -144,25 +144,9 @@ logout() { | |||||||
|   rm -rf token.json |   rm -rf token.json | ||||||
| } | } | ||||||
|  |  | ||||||
| venuecount() { |  | ||||||
|     curl ${FLAGS} "https://${OWPROV}/api/v1/venue?countOnly=true" \ |  | ||||||
|         -H "Content-Type: application/json" \ |  | ||||||
|         -H "Authorization: Bearer ${token}" \ |  | ||||||
|         -H "accept: application/json" > ${result_file} |  | ||||||
|     jq < ${result_file} |  | ||||||
| } |  | ||||||
|  |  | ||||||
| contactcount() { |  | ||||||
|     curl ${FLAGS} "https://${OWPROV}/api/v1/contact?countOnly=true" \ |  | ||||||
|         -H "Content-Type: application/json" \ |  | ||||||
|         -H "Authorization: Bearer ${token}" \ |  | ||||||
|         -H "Accept: application/json" > ${result_file} |  | ||||||
|     jq < ${result_file} |  | ||||||
| } |  | ||||||
|  |  | ||||||
| setloglevel() { | setloglevel() { | ||||||
|     payload="{ \"command\" : \"setloglevel\" , \"subsystems\" : [ { \"tag\" : \"$1\" , \"value\" : \"$2\" } ] }" |     payload="{ \"command\" : \"setloglevel\" , \"subsystems\" : [ { \"tag\" : \"$1\" , \"value\" : \"$2\" } ] }" | ||||||
|     curl  ${FLAGS} -X POST "https://${OWPROV}/api/v1/system" \ |     curl  ${FLAGS} -X POST "https://${OWANALYTICS}/api/v1/system" \ | ||||||
|         -H "Accept: application/json" \ |         -H "Accept: application/json" \ | ||||||
|         -H "Content-Type: application/json" \ |         -H "Content-Type: application/json" \ | ||||||
|         -H "Authorization: Bearer ${token}" \ |         -H "Authorization: Bearer ${token}" \ | ||||||
| @@ -171,7 +155,7 @@ setloglevel() { | |||||||
|  |  | ||||||
| getloglevels() { | getloglevels() { | ||||||
|     payload="{ \"command\" : \"getloglevels\" }" |     payload="{ \"command\" : \"getloglevels\" }" | ||||||
|     curl  ${FLAGS} -X POST "https://${OWPROV}/api/v1/system" \ |     curl  ${FLAGS} -X POST "https://${OWANALYTICS}/api/v1/system" \ | ||||||
|         -H "Accept: application/json" \ |         -H "Accept: application/json" \ | ||||||
|         -H "Content-Type: application/json" \ |         -H "Content-Type: application/json" \ | ||||||
|         -H "Authorization: Bearer ${token}" \ |         -H "Authorization: Bearer ${token}" \ | ||||||
| @@ -180,7 +164,7 @@ getloglevels() { | |||||||
|  |  | ||||||
| getloglevelnames() { | getloglevelnames() { | ||||||
|     payload="{ \"command\" : \"getloglevelnames\" }" |     payload="{ \"command\" : \"getloglevelnames\" }" | ||||||
|     curl  ${FLAGS} -X POST "https://${OWPROV}/api/v1/system" \ |     curl  ${FLAGS} -X POST "https://${OWANALYTICS}/api/v1/system" \ | ||||||
|         -H "Accept: application/json" \ |         -H "Accept: application/json" \ | ||||||
|         -H "Content-Type: application/json" \ |         -H "Content-Type: application/json" \ | ||||||
|         -H "Authorization: Bearer ${token}" \ |         -H "Authorization: Bearer ${token}" \ | ||||||
| @@ -189,7 +173,7 @@ getloglevelnames() { | |||||||
|  |  | ||||||
| getsubsystemnames() { | getsubsystemnames() { | ||||||
|     payload="{ \"command\" : \"getsubsystemnames\" }" |     payload="{ \"command\" : \"getsubsystemnames\" }" | ||||||
|     curl  ${FLAGS} -X POST "https://${OWPROV}/api/v1/system" \ |     curl  ${FLAGS} -X POST "https://${OWANALYTICS}/api/v1/system" \ | ||||||
|         -H "Accept: application/json" \ |         -H "Accept: application/json" \ | ||||||
|         -H "Content-Type: application/json" \ |         -H "Content-Type: application/json" \ | ||||||
|         -H "Authorization: Bearer ${token}" \ |         -H "Authorization: Bearer ${token}" \ | ||||||
| @@ -197,7 +181,7 @@ getsubsystemnames() { | |||||||
| } | } | ||||||
|  |  | ||||||
| systeminfo() { | systeminfo() { | ||||||
|     curl  ${FLAGS} -X GET "https://${OWPROV}/api/v1/system?command=info" \ |     curl  ${FLAGS} -X GET "https://${OWANALYTICS}/api/v1/system?command=info" \ | ||||||
|     -H "Accept: application/json" \ |     -H "Accept: application/json" \ | ||||||
|     -H "Authorization: Bearer ${token}" > ${result_file} |     -H "Authorization: Bearer ${token}" > ${result_file} | ||||||
|     jq < ${result_file} |     jq < ${result_file} | ||||||
| @@ -205,7 +189,7 @@ systeminfo() { | |||||||
|  |  | ||||||
| reloadsubsystem() { | reloadsubsystem() { | ||||||
|     payload="{ \"command\" : \"reload\", \"subsystems\" : [ \"$1\" ] }" |     payload="{ \"command\" : \"reload\", \"subsystems\" : [ \"$1\" ] }" | ||||||
|     curl  ${FLAGS} -X POST "https://${OWPROV}/api/v1/system" \ |     curl  ${FLAGS} -X POST "https://${OWANALYTICS}/api/v1/system" \ | ||||||
|         -H "Accept: application/json" \ |         -H "Accept: application/json" \ | ||||||
|         -H "Content-Type: application/json" \ |         -H "Content-Type: application/json" \ | ||||||
|         -H "Authorization: Bearer ${token}" \ |         -H "Authorization: Bearer ${token}" \ | ||||||
|   | |||||||
| @@ -1 +0,0 @@ | |||||||
| {"children":[{"children":[{"children":[{"children":[],"name":"Ottawa Operations","type":"entity","uuid":"323054d0-3ff0-11ec-82ff-061b87871e04","venues":[{"children":[],"name":"Living Lab","type":"venue","uuid":"4159ea84-3ff0-11ec-9edb-061b87871e04"}]}],"name":"Ontario","type":"entity","uuid":"21dfa464-3ff0-11ec-9a86-061b87871e04","venues":[]},{"children":[{"children":[],"name":"Quebec","type":"entity","uuid":"27b74e1b-52d7-4414-a1b4-47574c799beb","venues":[]},{"children":[],"name":"Ontario","type":"entity","uuid":"3cb15a80-3550-11ec-9a22-061b87871e04","venues":[{"children":[],"name":"CN Tower","type":"venue","uuid":"3cb28f0e-3550-11ec-acfa-061b87871e04"},{"children":[],"name":"Rogers Center","type":"venue","uuid":"3cb3c798-3550-11ec-8c1a-061b87871e04"}]},{"children":[],"name":"BC","type":"entity","uuid":"3cb503c4-3550-11ec-b436-061b87871e04","venues":[{"children":[],"name":"BC Place","type":"venue","uuid":"3cb76452-3550-11ec-a5ab-061b87871e04"},{"children":[],"name":"Stanley Park","type":"venue","uuid":"3cb8b230-3550-11ec-bbe6-061b87871e04"},{"children":[],"name":"MegaLab","type":"venue","uuid":"a73a23c4-6f3d-4031-bc92-d28c205f2d85"},{"children":[],"name":"Bowen Development","type":"venue","uuid":"d656500b-9f00-4c09-9096-e209085c2a3e"}]}],"name":"Provinces","type":"entity","uuid":"3cac92ca-3550-11ec-b360-061b87871e04","venues":[]}],"name":"Canada","type":"entity","uuid":"3cab2c32-3550-11ec-8a03-061b87871e04","venues":[]},{"children":[],"name":"USA","type":"entity","uuid":"6392c6b3-ef48-4b81-8785-1b5b4888bbd2","venues":[]},{"children":[{"children":[],"name":"Hamburg","type":"entity","uuid":"5939f995-e059-439d-ab0c-29a6f7c0a495","venues":[]}],"name":"Germany","type":"entity","uuid":"6fb5662d-dc48-4fbd-b8f9-69d0308bb902","venues":[]},{"children":[],"name":"Test Land","type":"entity","uuid":"70161a6f-98af-45d7-b0ed-e6b15ba5d84e","venues":[{"children":[],"name":"Test","type":"venue","uuid":"1d06b289-449e-4669-abc9-1f2dcdd1fbbc"}]}],"name":"World","type":"entity","uuid":"0000-0000-0000","venues":[]} |  | ||||||
		Reference in New Issue
	
	Block a user
	 Dmitry Dunaev
					Dmitry Dunaev