|
|
|
@ -50,10 +50,13 @@ node() { |
|
|
|
// To run the integration tests when using APIcast SaaS instances, we need |
|
|
|
// to fetch the proxy definition to extract the staging public url |
|
|
|
def proxy = service.readProxy("sandbox") |
|
|
|
sh """set -e +x |
|
|
|
curl -f -k -w "GetLocation: %{http_code}\n" -o /dev/null -s ${proxy.sandbox_endpoint}/api/location -H 'api-key: ${service.applications[0].userkey}' |
|
|
|
curl -f -k -w "GetTimeframe: %{http_code}\n" -o /dev/null -s ${proxy.sandbox_endpoint}/api/timeframe -H 'api-key: ${service.applications[0].userkey}' |
|
|
|
curl -f -k -w "GetParticipants: %{http_code}\n" -o /dev/null -s ${proxy.sandbox_endpoint}/api/participants -H 'api-key: ${service.applications[0].userkey}' |
|
|
|
def userkey = service.applications[0].userkey |
|
|
|
sh """set -e |
|
|
|
echo "Public Staging Base URL is ${proxy.sandbox_endpoint}" |
|
|
|
echo "userkey is ${userkey}" |
|
|
|
curl -sfk -w "ListBeers: %{http_code}\n" -o /dev/null ${proxy.sandbox_endpoint}/api/location -H 'api-key: ${userkey}' |
|
|
|
curl -sfk -w "GetBeer: %{http_code}\n" -o /dev/null ${proxy.sandbox_endpoint}/api/timeframe -H 'api-key: ${userkey}' |
|
|
|
curl -sfk -w "FindBeersByStatus: %{http_code}\n" -o /dev/null ${proxy.sandbox_endpoint}/api/participants -H 'api-key: ${userkey}' |
|
|
|
""" |
|
|
|
|
|
|
|
// Promote to production |
|
|
|
@ -98,10 +101,13 @@ node() { |
|
|
|
// To run the integration tests when using APIcast SaaS instances, we need |
|
|
|
// to fetch the proxy definition to extract the staging public url |
|
|
|
def proxy = service.readProxy("sandbox") |
|
|
|
sh """set -e +x |
|
|
|
curl -f -k -w "GetLocation: %{http_code}\n" -o /dev/null -s ${proxy.sandbox_endpoint}/api/location -H 'api-key: ${service.applications[0].userkey}' |
|
|
|
curl -f -k -w "GetTimeframe: %{http_code}\n" -o /dev/null -s ${proxy.sandbox_endpoint}/api/timeframe -H 'api-key: ${service.applications[0].userkey}' |
|
|
|
curl -f -k -w "GetParticipants: %{http_code}\n" -o /dev/null -s ${proxy.sandbox_endpoint}/api/participants -H 'api-key: ${service.applications[0].userkey}' |
|
|
|
def userkey = service.applications[0].userkey |
|
|
|
sh """set -e |
|
|
|
echo "Public Staging Base URL is ${proxy.sandbox_endpoint}" |
|
|
|
echo "userkey is ${userkey}" |
|
|
|
curl -sfk -w "ListBeers: %{http_code}\n" -o /dev/null ${proxy.sandbox_endpoint}/api/location -H 'api-key: ${userkey}' |
|
|
|
curl -sfk -w "GetBeer: %{http_code}\n" -o /dev/null ${proxy.sandbox_endpoint}/api/timeframe -H 'api-key: ${userkey}' |
|
|
|
curl -sfk -w "FindBeersByStatus: %{http_code}\n" -o /dev/null ${proxy.sandbox_endpoint}/api/participants -H 'api-key: ${userkey}' |
|
|
|
""" |
|
|
|
|
|
|
|
// Promote to production |
|
|
|
@ -146,10 +152,13 @@ node() { |
|
|
|
// To run the integration tests when using APIcast SaaS instances, we need |
|
|
|
// to fetch the proxy definition to extract the staging public url |
|
|
|
def proxy = service.readProxy("sandbox") |
|
|
|
sh """set -e +x |
|
|
|
curl -f -k -w "GetLocation: %{http_code}\n" -o /dev/null -s ${proxy.sandbox_endpoint}/api/location -H 'api-key: ${service.applications[0].userkey}' |
|
|
|
curl -f -k -w "GetTimeframe: %{http_code}\n" -o /dev/null -s ${proxy.sandbox_endpoint}/api/timeframe -H 'api-key: ${service.applications[0].userkey}' |
|
|
|
curl -f -k -w "GetParticipants: %{http_code}\n" -o /dev/null -s ${proxy.sandbox_endpoint}/api/participants -H 'api-key: ${service.applications[0].userkey}' |
|
|
|
def userkey = service.applications[0].userkey |
|
|
|
sh """set -e |
|
|
|
echo "Public Staging Base URL is ${proxy.sandbox_endpoint}" |
|
|
|
echo "userkey is ${userkey}" |
|
|
|
curl -sfk -w "ListBeers: %{http_code}\n" -o /dev/null ${proxy.sandbox_endpoint}/api/location -H 'api-key: ${userkey}' |
|
|
|
curl -sfk -w "GetBeer: %{http_code}\n" -o /dev/null ${proxy.sandbox_endpoint}/api/timeframe -H 'api-key: ${userkey}' |
|
|
|
curl -sfk -w "FindBeersByStatus: %{http_code}\n" -o /dev/null ${proxy.sandbox_endpoint}/api/participants -H 'api-key: ${userkey}' |
|
|
|
""" |
|
|
|
|
|
|
|
// Promote to production |
|
|
|
|