blob: 3efc1b45c9d9620baeb3de2004dec998a0b4042f [file] [log] [blame]
Dirk Huss78be04b2015-11-25 15:11:49 +01001#!/bin/bash
Juergen Gehring07d75732017-02-28 03:57:20 -08002# Copyright (C) 2015-2017 Bayerische Motoren Werke Aktiengesellschaft (BMW AG)
Dirk Huss78be04b2015-11-25 15:11:49 +01003# 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
7FAIL=0
8
9export VSOMEIP_CONFIGURATION=application_test_no_dispatch_threads.json
10./application_test
11
12if [ $? -ne 0 ]
13then
14 ((FAIL+=1))
15fi
16
17export VSOMEIP_CONFIGURATION=application_test.json
18./application_test
19
20if [ $? -ne 0 ]
21then
22 ((FAIL+=1))
23fi
24
Jürgen Gehring273814c2016-09-20 03:59:53 -070025cat <<End-of-message
26*******************************************************************************
27*******************************************************************************
28** Now running same tests with vsomeipd
29*******************************************************************************
30*******************************************************************************
31End-of-message
32export VSOMEIP_CONFIGURATION=application_test_no_dispatch_threads_daemon.json
33../daemon/./vsomeipd &
34DAEMON_PID=$!
35./application_test
36if [ $? -ne 0 ]
37then
38 ((FAIL+=1))
39fi
40
41kill $DAEMON_PID
Jürgen Gehring13754322016-10-11 05:20:33 -070042wait $DAEMON_PID
Jürgen Gehring273814c2016-09-20 03:59:53 -070043
44export VSOMEIP_CONFIGURATION=application_test_daemon.json
45../daemon/./vsomeipd &
46DAEMON_PID=$!
47./application_test
48if [ $? -ne 0 ]
49then
50 ((FAIL+=1))
51fi
52
53kill $DAEMON_PID
54
Dirk Huss78be04b2015-11-25 15:11:49 +010055# Check if both exited successfully
56if [ $FAIL -eq 0 ]
57then
58 exit 0
59else
60 exit 1
61fi