blob: 7ff1968f269604668999bfa46926cb7cc1ada48d [file] [log] [blame]
BjornMagnussonXAa5491572021-05-04 09:21:24 +02001#!/bin/bash
2
3# ============LICENSE_START===============================================
4# Copyright (C) 2021 Nordix Foundation. All rights reserved.
5# ========================================================================
6# Licensed under the Apache License, Version 2.0 (the "License");
7# you may not use this file except in compliance with the License.
8# You may obtain a copy of the License at
9#
10# http://www.apache.org/licenses/LICENSE-2.0
11#
12# Unless required by applicable law or agreed to in writing, software
13# distributed under the License is distributed on an "AS IS" BASIS,
14# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15# See the License for the specific language governing permissions and
16# limitations under the License.
17# ============LICENSE_END=================================================
18#
19
20# Automated test script for callback receiver container
21
22
23echo "NOTE - No automatic response check - check manually"
24echo "All call shall return a json struct"
25echo ""
26
27CMD="curl --proxy localhost:8080 localhost:8081"
28echo "Running cmd: "$CMD
29$CMD
30echo ""
31if [ $? -eq 0 ]; then
32 echo "CMD OK"
33else
34 echo "CMD FAIL"
BjornMagnussonXA674793d2021-05-06 19:49:17 +020035 exti 1
BjornMagnussonXAa5491572021-05-04 09:21:24 +020036fi
37echo ""
38
39CMD="curl --proxy localhost:8080 -k https://localhost:8434"
40echo "Running cmd: "$CMD
41$CMD
42echo ""
43if [ $? -eq 0 ]; then
44 echo "CMD OK"
45else
46 echo "CMD FAIL"
BjornMagnussonXA674793d2021-05-06 19:49:17 +020047 exti 1
BjornMagnussonXAa5491572021-05-04 09:21:24 +020048fi
49echo ""
50
BjornMagnussonXA674793d2021-05-06 19:49:17 +020051CMD="curl --proxy-insecure --proxy https://localhost:8433 localhost:8081"
BjornMagnussonXAa5491572021-05-04 09:21:24 +020052echo "Running cmd: "$CMD
53$CMD
54echo ""
55if [ $? -eq 0 ]; then
56 echo "CMD OK"
57else
58 echo "CMD FAIL"
BjornMagnussonXA674793d2021-05-06 19:49:17 +020059 exti 1
BjornMagnussonXAa5491572021-05-04 09:21:24 +020060fi
61echo ""
62
BjornMagnussonXA674793d2021-05-06 19:49:17 +020063CMD="curl --proxy-insecure --proxy https://localhost:8433 -k https://localhost:8434"
BjornMagnussonXAa5491572021-05-04 09:21:24 +020064echo "Running cmd: "$CMD
65$CMD
66echo ""
67if [ $? -eq 0 ]; then
68 echo "CMD OK"
69else
70 echo "CMD FAIL"
BjornMagnussonXA674793d2021-05-06 19:49:17 +020071 exti 1
BjornMagnussonXAa5491572021-05-04 09:21:24 +020072fi
73echo ""
74
75echo "DONE"