Dirk Huss | 78be04b | 2015-11-25 15:11:49 +0100 | [diff] [blame] | 1 | #!/bin/bash |
Juergen Gehring | 07d7573 | 2017-02-28 03:57:20 -0800 | [diff] [blame] | 2 | # Copyright (C) 2015-2017 Bayerische Motoren Werke Aktiengesellschaft (BMW AG) |
Dirk Huss | 78be04b | 2015-11-25 15:11:49 +0100 | [diff] [blame] | 3 | # This Source Code Form is subject to the terms of the Mozilla Public |
| 4 | # License, v. 2.0. If a copy of the MPL was not distributed with this |
| 5 | # file, You can obtain one at http://mozilla.org/MPL/2.0/. |
| 6 | |
| 7 | FAIL=0 |
| 8 | |
| 9 | export VSOMEIP_CONFIGURATION=application_test_no_dispatch_threads.json |
| 10 | ./application_test |
| 11 | |
| 12 | if [ $? -ne 0 ] |
| 13 | then |
| 14 | ((FAIL+=1)) |
| 15 | fi |
| 16 | |
| 17 | export VSOMEIP_CONFIGURATION=application_test.json |
| 18 | ./application_test |
| 19 | |
| 20 | if [ $? -ne 0 ] |
| 21 | then |
| 22 | ((FAIL+=1)) |
| 23 | fi |
| 24 | |
Jürgen Gehring | 273814c | 2016-09-20 03:59:53 -0700 | [diff] [blame] | 25 | cat <<End-of-message |
| 26 | ******************************************************************************* |
| 27 | ******************************************************************************* |
| 28 | ** Now running same tests with vsomeipd |
| 29 | ******************************************************************************* |
| 30 | ******************************************************************************* |
| 31 | End-of-message |
| 32 | export VSOMEIP_CONFIGURATION=application_test_no_dispatch_threads_daemon.json |
| 33 | ../daemon/./vsomeipd & |
| 34 | DAEMON_PID=$! |
| 35 | ./application_test |
| 36 | if [ $? -ne 0 ] |
| 37 | then |
| 38 | ((FAIL+=1)) |
| 39 | fi |
| 40 | |
| 41 | kill $DAEMON_PID |
Jürgen Gehring | 1375432 | 2016-10-11 05:20:33 -0700 | [diff] [blame] | 42 | wait $DAEMON_PID |
Jürgen Gehring | 273814c | 2016-09-20 03:59:53 -0700 | [diff] [blame] | 43 | |
| 44 | export VSOMEIP_CONFIGURATION=application_test_daemon.json |
| 45 | ../daemon/./vsomeipd & |
| 46 | DAEMON_PID=$! |
| 47 | ./application_test |
| 48 | if [ $? -ne 0 ] |
| 49 | then |
| 50 | ((FAIL+=1)) |
| 51 | fi |
| 52 | |
| 53 | kill $DAEMON_PID |
| 54 | |
Dirk Huss | 78be04b | 2015-11-25 15:11:49 +0100 | [diff] [blame] | 55 | # Check if both exited successfully |
| 56 | if [ $FAIL -eq 0 ] |
| 57 | then |
| 58 | exit 0 |
| 59 | else |
| 60 | exit 1 |
| 61 | fi |