You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Blair Zajac <bl...@orcaware.com> on 2006/09/22 23:32:41 UTC

Re: svn commit: r21620 - trunk/build

blair@tigris.org wrote:
> Author: blair
> Date: Fri Sep 22 16:29:27 2006
> New Revision: 21620
> 
> Log:
> * build/run_tests.py
>   (_run_test):
>     Move code common to two branches in a if test outside the if test.
> 
> 
> Modified:
>    trunk/build/run_tests.py
> 
> Modified: trunk/build/run_tests.py
> URL: http://svn.collab.net/viewvc/svn/trunk/build/run_tests.py?pathrev=21620&r1=21619&r2=21620
> ==============================================================================
> --- trunk/build/run_tests.py	(original)
> +++ trunk/build/run_tests.py	Fri Sep 22 16:29:27 2006
> @@ -94,28 +94,23 @@
>        progname = sys.executable
>        cmdline = [quote(progname),
>                   quote(os.path.join(self.srcdir, prog))]
> -      if self.verbose is not None:
> -        cmdline.append('--verbose')
> -      if self.cleanup is not None:
> -        cmdline.append('--cleanup')
>        if self.base_url is not None:
>          cmdline.append(quote('--url=' + self.base_url))
> -      if self.fs_type is not None:
> -        cmdline.append(quote('--fs-type=' + self.fs_type))
>      elif os.access(prog, os.X_OK):
>        progname = './' + progbase
>        cmdline = [quote(progname),
>                   quote('--srcdir=' + os.path.join(self.srcdir, progdir))]
> -      if self.verbose is not None:
> -        cmdline.append('--verbose')
> -      if self.cleanup is not None:
> -        cmdline.append('--cleanup')
> -      if self.fs_type is not None:
> -        cmdline.append(quote('--fs-type=' + self.fs_type))
>      else:
>        print 'Don\'t know what to do about ' + progbase
>        sys.exit(1)
>  
> +    if self.verbose is not None:
> +      cmdline.append('--verbose')
> +    if self.cleanup is not None:
> +      cmdline.append('--cleanup')
> +    if self.fs_type is not None:
> +      cmdline.append(quote('--fs-type=' + self.fs_type))
> +

I did this minor cleanup, but does anybody know why one branch of the above test 
has the following code while the other doesn't?

         if self.base_url is not None:
           cmdline.append(quote('--url=' + self.base_url))

Regards,
Blair

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: svn commit: r21620 - trunk/build

Posted by Daniel Rall <dl...@collab.net>.
On Fri, 22 Sep 2006, Blair Zajac wrote:
...
> I did this minor cleanup, but does anybody know why one branch of the above 
> test has the following code while the other doesn't?
> 
>         if self.base_url is not None:
>           cmdline.append(quote('--url=' + self.base_url))

Blair, it's been that way for years.  I'm guessing that second branch
is used by something test progs which are executable, but don't end in
.py (e.g. our C whitebox tests).

While we don't appear to support the "--url=" argument for the C
tests, adding it doesn't seem to hurt anything.


From svn_test_main.c:

static const apr_getopt_option_t cl_options[] =
{
  {"cleanup",       cleanup_opt, 0,
                    N_("remove test directories after success")},
  {"fs-type",       fstype_opt, 1,
                    N_("specify a filesystem backend type ARG")},
  {"list",          list_opt, 0,
                    N_("lists all the tests with their short description")},
  {"verbose",       verbose_opt, 0,
                    N_("print extra information")},
  {0,               0, 0, 0}
};