#!/bin/sh
#####################################################################
-# Copyright (c) 2012 Samsung Electronics Co., Ltd All Rights Reserved
+# Copyright (c) 2012-2014 Samsung Electronics Co., Ltd All Rights Reserved
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
echo "========================================================================="
echo $1
echo
- libsmack-test $2 $3
+ libsmack-test "${@:2}" # propagate all remaining arguments (except first)
+ ;;
+"smack-dbus")
+ echo "========================================================================="
+ echo "SMACK DBUS TEST"
+ echo
+ smack-dbus-tests "${@:2}"
;;
-
"libprivilege-control")
echo "========================================================================="
echo $1
echo
- libprivilege-control-test $2 $3
+ libprivilege-control-test "${@:2}"
;;
"ss-clientsmack")
echo "========================================================================="
echo "SECURITY SERVER TEST CLIENT SMACK"
echo
- security-server-tests-client-smack $2 $3
+ security-server-tests-client-smack "${@:2}"
;;
-"ss-label")
+"ss-stress")
echo "========================================================================="
- echo "SECURITY SERVER TEST LABEL"
+ echo "SECURITY SERVER TEST STRESS"
echo
- security-server-tests-label $2 $3
+ security-server-tests-stress "${@:2}"
;;
"ss-server")
echo "========================================================================="
echo "SECURITY SERVER TEST SERVER"
echo
- security-server-tests-server $2 $3
+ security-server-tests-server "${@:2}"
;;
"ss-api-speed")
echo "========================================================================="
echo "SECURITY SERVER MEASURER SERVER"
echo
- security-server-tests-api-speed $2 $3
+ security-server-tests-api-speed "${@:2}"
;;
"ss-password")
echo "========================================================================="
echo "SECURITY SERVER TEST PASSWORD"
echo
- security-server-tests-password $2 $3
+ security-server-tests-password "${@:2}"
;;
-"ss-dbus")
+"ss-privilege")
echo "========================================================================="
- echo "SECURITY SERVER TEST DBUS"
+ echo "SECURITY SERVER TEST PRIVILEGE"
echo
- security-server-tests-dbus $2 $3
+ security-server-tests-privilege "${@:2}"
+ ;;
+"security-manager")
+ echo "========================================================================="
+ echo "SECURITY MANAGER TESTS"
+ echo
+ security-manager-tests "${@:2}"
+ ;;
+"cynara")
+ echo "========================================================================="
+ echo "CYNARA TEST"
+ echo
+ cynara-test "${@:2}"
;;
-
*)
echo "Correct using:"
echo " security_test.sh <module> <args_for_module>"
echo
- echo "modules: smack, libprivilege-control, ss-clientsmack"
- echo " ss-label, ss-server, ss-api-speed, ss-password"
+ echo "modules: smack, smack-dbus, libprivilege-control, ss-clientsmack"
+ echo " ss-server, ss-api-speed, ss-password, ss-stress"
+ echo " ss-privilege, security-manager, cynara"
;;
esac