[CRIU] [PATCH] test/zdtm: add option -r to run test with specified name
Yicheng Qin
yichengq at google.com
Tue Aug 20 14:30:26 EDT 2013
Hi Andrew,
I write this patch to fix running test that is not in TEST_LIST.
But I am not sure whether it reaches your expect.
May you check it?
Thx!
On Tue, Aug 20, 2013 at 11:27 AM, Yicheng Qin <yichengq at google.com> wrote:
> The option can run test with specified name directly without check
> or match.
>
> It can be used to run experimental test that is not in TEST_LIST.
>
> Signed-off-by: Yicheng Qin <yichengq at google.com>
> ---
> test/zdtm.sh | 13 +++++++++++++
> 1 file changed, 13 insertions(+)
>
> diff --git a/test/zdtm.sh b/test/zdtm.sh
> index 275cc8d..7f34c8d 100755
> --- a/test/zdtm.sh
> +++ b/test/zdtm.sh
> @@ -158,6 +158,7 @@ PS_PORT=12345
> TCPDUMP_PID=
> COMPILE_ONLY=0
> BATCH_TEST=0
> +SPECIFIED_NAME_USED=0
>
> check_criu()
> {
> @@ -658,6 +659,11 @@ while :; do
> shift
> continue
> fi
> + if [ "$1" = "-r" ]; then
> + SPECIFIED_NAME_USED=1
> + shift
> + continue
> + fi
> break;
> done
>
> @@ -685,9 +691,16 @@ Options:
> -a <FILE>.tar.gz : save archive with dump files and logs
> -g : Generate executables only
> -n : Batch test
> + -r : Run test with specified name directly without match or check
> EOF
> elif [ "${1:0:1}" = '-' ]; then
> echo "unrecognized option $1"
> +elif [ $SPECIFIED_NAME_USED -eq 1 ]; then
> + if [ $# -eq 0 ]; then
> + echo "test name should be provided"
> + exit 1
> + fi
> + run_test $1 || case_error $t
> else
> if [ $COMPILE_ONLY -eq 0 ]; then
> check_mainstream || exit 1
> --
> 1.8.3
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openvz.org/pipermail/criu/attachments/20130820/5a5d5841/attachment-0001.html>
More information about the CRIU
mailing list