test suite reviews and discussions
 help / color / mirror / Atom feed
From: "Liu, Yong" <yong.liu@intel.com>
To: "Xu, HuilongX" <huilongx.xu@intel.com>, "dts@dpdk.org" <dts@dpdk.org>
Cc: "Xu, HuilongX" <huilongx.xu@intel.com>
Subject: Re: [dts] [PATCH V1 1/3] add re_run parameter
Date: Fri, 23 Jun 2017 16:42:20 +0000	[thread overview]
Message-ID: <86228AFD5BCD8E4EBFD2B90117B5E81E62E0D32B@SHSMSX103.ccr.corp.intel.com> (raw)
In-Reply-To: <1498197394-16220-1-git-send-email-huilongx.xu@intel.com>

Huilong,
Rerun is not supposed to be the default action for failed cases. The default value for rerun times should be zero, 

> -----Original Message-----
> From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of xu,huilong
> Sent: Thursday, June 22, 2017 10:57 PM
> To: dts@dpdk.org
> Cc: Xu, HuilongX <huilongx.xu@intel.com>
> Subject: [dts] [PATCH V1 1/3] add re_run parameter
> 
> add a new re_run parameter for failed case re run time. the default value
> is 1.
> 
> Signed-off-by: xu,huilong <huilongx.xu@intel.com>
> ---
>  framework/dts.py  | 7 +++++--
>  framework/main.py | 5 ++++-
>  2 files changed, 9 insertions(+), 3 deletions(-)
> 
> diff --git a/framework/dts.py b/framework/dts.py
> index 369599d..48be694 100644
> --- a/framework/dts.py
> +++ b/framework/dts.py
> @@ -424,7 +424,7 @@ def dts_run_suite(duts, tester, test_suites, target):
>  def run_all(config_file, pkgName, git, patch, skip_setup,
>              read_cache, project, suite_dir, test_cases,
>              base_dir, output_dir, verbose, virttype, debug,
> -            debugcase, commands):
> +            debugcase, re_run, commands):
>      """
>      Main process of DTS, it will run all test suites in the config file.
>      """
> @@ -465,6 +465,9 @@ def run_all(config_file, pkgName, git, patch,
> skip_setup,
>      if verbose is True:
>          logger.set_verbose()
> 
> +    if re_run < 1:
> +        re_run = 1
> +
>      logger.log_dir = output_dir
>      log_handler = getLogger('dts')
>      log_handler.config_execution('dts')
> @@ -520,7 +523,7 @@ def run_all(config_file, pkgName, git, patch,
> skip_setup,
> 
>          # init dut, tester crb
>          duts, tester = dts_crbs_init(crbInsts, skip_setup, read_cache,
> project, base_dir, serializer, virttype)
> -
> +        tester.set_re_run(re_run)
>          # register exit action
>          atexit.register(quit_execution, duts, tester)
> 
> diff --git a/framework/main.py b/framework/main.py
> index a018af0..de9d54f 100755
> --- a/framework/main.py
> +++ b/framework/main.py
> @@ -134,6 +134,9 @@ parser.add_argument('--debug',
>  parser.add_argument('--debugcase',
>                      action='store_true',
>                      help='enable debug mode in the first case, user can
> further debug')
> +parser.add_argument('--re_run',
> +                    default=1,
> +                    help='when case failed will re-run times, and this
> value must >= 1')
> 

Suggest add  "type=int" in re-run argument definition. 

>  parser.add_argument('--commands',
>                      action='append',
> @@ -156,4 +159,4 @@ dts.run_all(args.config_file, args.snapshot, args.git,
>              args.patch, args.skip_setup, args.read_cache,
>              args.project, args.suite_dir, args.test_cases,
>              args.dir, args.output, args.verbose,args.virttype,
> -            args.debug, args.debugcase, args.commands)
> +            args.debug, args.debugcase, args.re_run, args.commands)
> --
> 1.9.3

  parent reply	other threads:[~2017-06-23 16:42 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-23  5:56 xu,huilong
2017-06-23  5:56 ` [dts] [PATCH V1 2/3] update exec case function xu,huilong
2017-06-23  5:56 ` [dts] [PATCH V1 3/3] update case result write function xu,huilong
2017-06-23 17:05   ` Liu, Yong
2017-06-28  5:41     ` Xu, HuilongX
2017-06-23 16:42 ` Liu, Yong [this message]
2017-06-28  5:38   ` [dts] [PATCH V1 1/3] add re_run parameter Xu, HuilongX

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=86228AFD5BCD8E4EBFD2B90117B5E81E62E0D32B@SHSMSX103.ccr.corp.intel.com \
    --to=yong.liu@intel.com \
    --cc=dts@dpdk.org \
    --cc=huilongx.xu@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).