-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathtest
executable file
·38 lines (36 loc) · 1.97 KB
/
test
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
30
31
32
33
34
35
36
37
38
#!/bin/sh
# -------------------------------------------------------------------------------------------
# @author: Araf Karsh Hamid
# -------------------------------------------------------------------------------------------
PORT=9090
API_VERSION=v1
SERVICE=`getServiceName 3`
echo "---------------------------------------------------------------------------------------"
echo "Testing $SERVICE Microservice"
echo "---------------------------------------------------------------------------------------"
echo "---------------------------------------------------------------------------------------"
echo "curl localhost:$PORT/api/$API_VERSION/$SERVICE/service/home"
curl localhost:$PORT/api/$API_VERSION/$SERVICE/service/home
echo ""
echo "---------------------------------------------------------------------------------------"
echo "curl localhost:$PORT/api/$API_VERSION/$SERVICE/service/live"
curl localhost:$PORT/api/$API_VERSION/$SERVICE/service/live
echo ""
echo "---------------------------------------------------------------------------------------"
echo "curl localhost:$PORT/api/$API_VERSION/$SERVICE/service/ready"
curl localhost:$PORT/api/$API_VERSION/$SERVICE/service/ready
echo ""
echo "---------------------------------------------------------------------------------------"
echo "curl -X POST localhost:$PORT/api/$API_VERSION/$SERVICE/service/restart"
curl -X POST localhost:$PORT/api/$API_VERSION/$SERVICE/service/restart
echo ""
echo "---------------------------------------------------------------------------------------"
sleep 3
echo "curl localhost:$PORT/api/$API_VERSION/$SERVICE/service/home"
curl localhost:$PORT/api/$API_VERSION/$SERVICE/service/home
echo ""
echo "---------------------------------------------------------------------------------------"
echo "curl localhost:$PORT/api/$API_VERSION/$SERVICE/service/ready"
curl localhost:$PORT/api/$API_VERSION/$SERVICE/service/ready
echo ""
echo "---------------------------------------------------------------------------------------"