X-Git-Url: https://git.teslayout.com/public/public/public/?a=blobdiff_plain;f=example%2Fdiameter%2Flauncher%2Fdeployments%2Fst-client%2Fprogram.sh;h=030877134b9fa83e4b4fcb71676d3d8bfe5d7d7c;hb=204a2f272da5c07340a1c3380ad59cec9a81f012;hp=93cd8661c22600e39a46d6500440bd9f36f8d167;hpb=8de835b706e08eac4bb8fca78c1f373bfb29191f;p=anna.git diff --git a/example/diameter/launcher/deployments/st-client/program.sh b/example/diameter/launcher/deployments/st-client/program.sh index 93cd866..0308771 100755 --- a/example/diameter/launcher/deployments/st-client/program.sh +++ b/example/diameter/launcher/deployments/st-client/program.sh @@ -22,10 +22,18 @@ _exit() { usage() { echo "Usage: $0 [-s]" echo - echo " test stuff directory: contains msk files, specially a testcase description with xml files referenced." - echo " Those files, adding .msk extension, shall exists in the same directory. For example:" + echo " Performs test case programming from scratch (current test cases will be dropped from ADML involved instances)." + echo + echo " test stuff directory: contains msk files, specially a testcase file with xml files referenced inside. Those" + echo " xml files (without the .msk extension) shall exists in the directory. For example:" + echo echo " $0 st_examples/DynamicQualification" echo + echo " Optionally, a file called 'specific' could exists containing testcase-specific information," + echo " which normally will be used to specify database sentences. This file will be accumulated" + echo " as a cloning seed over the file 'specific.all' created on test stuff directory." + echo + echo echo " -s: start testing just after programming, using desired rate: $DESIRED_RATE test cases per second." [ $ADML_INSTANCES -gt 1 ] && echo " In your case, with $ADML_INSTANCES, a rate of $RATE_PER_INSTANCE ttps will be send per instance." echo @@ -52,6 +60,8 @@ miss_conf= echo [ -z "$1" ] && usage +./operation.sh --ping +[ $? -ne 0 ] && _exit "Programming aborted (some ADML client process is not running) !" TESTCASE_DIR=$1 AUTOSTART=$2 @@ -60,10 +70,11 @@ TESTCASE=( `ls $TESTCASE_DIR/testcase*msk 2>/dev/null` ) TESTCASE_FILES=${#TESTCASE[@]} [ $TESTCASE_FILES -ne 1 ] && _exit "One and only one 'testcase*msk' file must be present !!" -#CLONE_GROUPS=1 MAX_NUMBER_GROUPS=$(grep ^MAX_NUMBER_GROUPS= clone.sh | cut -d= -f2) -ADML_INSTANCES=`cat .st_conf_adml_instances` CLONE_GROUPS=$((MAX_NUMBER_GROUPS/ADML_INSTANCES)) +#CLONE_GROUPS=1 +specific= +[ -f $TESTCASE_DIR/specific ] && specific=specific children_before=$(children) while read -r line @@ -72,7 +83,7 @@ do ini_seq=$(echo $line | awk '{ print $2 }') fin_seq=$(echo $line | awk '{ print $3 }') ADML_DIR=`readlink -f ADMLS/ADML-$instance` - ./clone.sh $ADML_DIR $TESTCASE $ini_seq $fin_seq $CLONE_GROUPS & + ./clone.sh $ADML_DIR $TESTCASE $ini_seq $fin_seq $CLONE_GROUPS $specific & done < $PROGRAM_LAYOUT_FILE @@ -92,6 +103,17 @@ echo echo "Configuring repeat cycles ..." ./operation.sh "test|repeats|$REPEATS" +if [ -n "$specific" ] +then + echo "A new file '$TESTCASE_DIR/specific.all' has been created." + echo "Probably you need to apply it before starting traffic." + echo + echo "Press ENTER to continue, CTRL-C to abort ..." + read dummy +fi + +echo +echo start_testing= if [ "$AUTOSTART" = "-s" ] then @@ -104,6 +126,9 @@ else rate_per_instance=$((desired_rate/$ADML_INSTANCES)) [ $rate_per_instance -lt 1 ] && rate_per_instance=1 ./operation.sh "test|ttps|$rate_per_instance" + else + echo "Remember that you could start traffic using:" + echo " ./operation.sh \"test|ttps|\"" fi fi