[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: svn commit: r25292 - trunk/subversion/tests/cmdline

From: Malcolm Rowe <malcolm-svn-dev_at_farside.org.uk>
Date: 2007-06-05 14:41:42 CEST

On Tue, Jun 05, 2007 at 05:12:29AM -0700, kameshj@tigris.org wrote:
> Currently 'authz_svnserve_anon_access_read' test is executed for ra_dav
> tests too. It is due to 'svntest.main.is_ra_type_dav()', changing that to
> 'svntest.main.is_ra_type_dav' should skip this testcase for ra_dav tests.

This is a poor log message: it should primarily describe the change, not
a description of the current problem.

But more importantly...

> @@ -861,7 +861,7 @@
> authz_validate,
> authz_locking,
> Skip(authz_svnserve_anon_access_read,
> - svntest.main.is_ra_type_dav()),
> + svntest.main.is_ra_type_dav),
> ]
>

... does this actually work? Skip() takes a conditional (evaluated
at parse time), while XFail() takes a lambda (evaluated immediately
prior to test execution).

That discrepancy is annoying, and I suspect that is_ra_type_dav() may
actually not work (i.e. always returns false) at the point that this
list is evaluated (because argument parsing doesn't happen until later),
and so whereas we'd never Skip the test before, we now always skip it.

See for example the way that the test recover_fsfs (in svnadmin_tests.py)
works:

def recover_fsfs(sbox):
  "recover a repository (FSFS only)"

  # Ideally, we'd include a variant of this in a Skip() condition, except
  # that Skip() evaluates its value at construction, rather than accepting
  # a lambda to evaluate later. This pragma isn't available at test
  # construction time.
  if not svntest.main.is_fs_type_fsfs():
    raise svntest.Skip

Regards,
Malcolm

  • application/pgp-signature attachment: stored
Received on Tue Jun 5 21:34:57 2007

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.