File tree Expand file tree Collapse file tree 8 files changed +49
-15
lines changed Expand file tree Collapse file tree 8 files changed +49
-15
lines changed Original file line number Diff line number Diff line change 22# aes-cmd-test.sh
33# AES encryption test for wolfProvider
44#
5- # NOTE: This script is designed to be called from do-cmd-tests.sh
6- # Do not run this script directly - use do-cmd-tests.sh instead
7- #
85# Copyright (C) 2006-2025 wolfSSL Inc.
96#
107# This file is part of wolfProvider.
2522SCRIPT_DIR=" $( cd " $( dirname " ${BASH_SOURCE[0]} " ) " & > /dev/null && pwd ) "
2623source " ${SCRIPT_DIR} /cmd-test-common.sh"
2724source " ${SCRIPT_DIR} /clean-cmd-test.sh"
25+
26+ if [ -z " ${DO_CMD_TESTS:- } " ]; then
27+ echo " This script is designed to be called from do-cmd-tests.sh"
28+ echo " Do not run this script directly - use do-cmd-tests.sh instead"
29+ exit 1
30+ fi
31+
2832cmd_test_init " aes-test.log"
2933clean_cmd_test " aes"
3034
Original file line number Diff line number Diff line change 1717# You should have received a copy of the GNU General Public License
1818# along with wolfProvider. If not, see <http://www.gnu.org/licenses/>.
1919
20+ if [ -z " ${DO_CMD_TESTS:- } " ]; then
21+ echo " This script is designed to be called from do-cmd-tests.sh"
22+ echo " Do not run this script directly - use do-cmd-tests.sh instead"
23+ exit 1
24+ fi
25+
2026# Function to clean up specific command test artifacts
2127clean_cmd_test () {
2228 local test_type=$1
Original file line number Diff line number Diff line change @@ -23,6 +23,12 @@ WOLFPROV_REPLACE_DEFAULT=${WOLFPROV_REPLACE_DEFAULT:-0}
2323WOLFPROV_FIPS=${WOLFPROV_FIPS:- 0}
2424WOLFPROV_INSTALLED=${WOLFPROV_INSTALLED:- 0}
2525
26+ if [ -z " ${DO_CMD_TESTS:- } " ]; then
27+ echo " This script is designed to be called from do-cmd-tests.sh"
28+ echo " Do not run this script directly - use do-cmd-tests.sh instead"
29+ exit 1
30+ fi
31+
2632# Function to detect wolfProvider installation mode
2733detect_wolfprovider_mode () {
2834 if [ -z " ${REPO_ROOT:- } " ]; then
Original file line number Diff line number Diff line change @@ -24,6 +24,9 @@ SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
2424REPO_ROOT=" $( cd " ${SCRIPT_DIR} /../.." & > /dev/null && pwd ) "
2525UTILS_DIR=" ${REPO_ROOT} /scripts"
2626
27+ # Flag to indicate that this script is being called from do-cmd-tests.sh
28+ export DO_CMD_TESTS=1
29+
2730# Parse command-line arguments
2831RUN_HASH=0
2932RUN_AES=0
Original file line number Diff line number Diff line change 22# ecc-cmd-test.sh
33# ECC key generation test for wolfProvider
44#
5- # NOTE: This script is designed to be called from do-cmd-tests.sh
6- # Do not run this script directly - use do-cmd-tests.sh instead
7- #
85# Copyright (C) 2006-2025 wolfSSL Inc.
96#
107# This file is part of wolfProvider.
2522SCRIPT_DIR=" $( cd " $( dirname " ${BASH_SOURCE[0]} " ) " & > /dev/null && pwd ) "
2623source " ${SCRIPT_DIR} /cmd-test-common.sh"
2724source " ${SCRIPT_DIR} /clean-cmd-test.sh"
25+
26+ if [ -z " ${DO_CMD_TESTS:- } " ]; then
27+ echo " This script is designed to be called from do-cmd-tests.sh"
28+ echo " Do not run this script directly - use do-cmd-tests.sh instead"
29+ exit 1
30+ fi
31+
2832cmd_test_init " ecc-test.log"
2933clean_cmd_test " ecc"
3034
Original file line number Diff line number Diff line change 22# hash-cmd-test.sh
33# Run hash command-line tests for wolfProvider
44#
5- # NOTE: This script is designed to be called from do-cmd-tests.sh
6- # Do not run this script directly - use do-cmd-tests.sh instead
7- #
85# Copyright (C) 2006-2025 wolfSSL Inc.
96#
107# This file is part of wolfProvider.
2522SCRIPT_DIR=" $( cd " $( dirname " ${BASH_SOURCE[0]} " ) " & > /dev/null && pwd ) "
2623source " ${SCRIPT_DIR} /cmd-test-common.sh"
2724source " ${SCRIPT_DIR} /clean-cmd-test.sh"
25+
26+ if [ -z " ${DO_CMD_TESTS:- } " ]; then
27+ echo " This script is designed to be called from do-cmd-tests.sh"
28+ echo " Do not run this script directly - use do-cmd-tests.sh instead"
29+ exit 1
30+ fi
31+
2832cmd_test_init " hash-test.log"
2933clean_cmd_test " hash"
3034
Original file line number Diff line number Diff line change 22# req-cmd-test.sh
33# Certificate request test for wolfProvider
44#
5- # NOTE: This script is designed to be called from do-cmd-tests.sh
6- # Do not run this script directly - use do-cmd-tests.sh instead
7- #
85# Copyright (C) 2006-2025 wolfSSL Inc.
96#
107# This file is part of wolfProvider.
2522SCRIPT_DIR=" $( cd " $( dirname " ${BASH_SOURCE[0]} " ) " & > /dev/null && pwd ) "
2623source " ${SCRIPT_DIR} /cmd-test-common.sh"
2724source " ${SCRIPT_DIR} /clean-cmd-test.sh"
25+
26+ if [ -z " ${DO_CMD_TESTS:- } " ]; then
27+ echo " This script is designed to be called from do-cmd-tests.sh"
28+ echo " Do not run this script directly - use do-cmd-tests.sh instead"
29+ exit 1
30+ fi
31+
2832cmd_test_init " req-test.log"
2933clean_cmd_test " req"
3034
Original file line number Diff line number Diff line change 22# rsa-cmd-test.sh
33# RSA and RSA-PSS key generation test for wolfProvider
44#
5- # NOTE: This script is designed to be called from do-cmd-tests.sh
6- # Do not run this script directly - use do-cmd-tests.sh instead
7- #
85# Copyright (C) 2006-2025 wolfSSL Inc.
96#
107# This file is part of wolfProvider.
@@ -28,6 +25,12 @@ source "${SCRIPT_DIR}/clean-cmd-test.sh"
2825cmd_test_init " rsa-test.log"
2926clean_cmd_test " rsa"
3027
28+ if [ -z " ${DO_CMD_TESTS:- } " ]; then
29+ echo " This script is designed to be called from do-cmd-tests.sh"
30+ echo " Do not run this script directly - use do-cmd-tests.sh instead"
31+ exit 1
32+ fi
33+
3134# Create test data and output directories
3235mkdir -p rsa_outputs
3336echo " This is test data for RSA signing and verification." > rsa_outputs/test_data.txt
You can’t perform that action at this time.
0 commit comments