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

Re: Failing test basic_tests.py 29 (check that repos root gets set on checkout)

From: Johan Corveleyn <jcorvel_at_gmail.com>
Date: Tue, 5 Jun 2012 13:58:51 +0200

On Tue, Jun 5, 2012 at 1:43 PM, Johan Corveleyn <jcorvel_at_gmail.com> wrote:
> On Tue, Jun 5, 2012 at 1:22 PM, Bert Huijben <bert_at_qqmail.nl> wrote:
>>
>>
>>> -----Original Message-----
>>> From: Johan Corveleyn [mailto:jcorvel_at_gmail.com]
>>> Sent: dinsdag 5 juni 2012 13:08
>>> To: Bert Huijben
>>> Cc: dev_at_subversion.apache.org
>>> Subject: Re: Failing test basic_tests.py 29 (check that repos root gets set on
>>> checkout)
>>>
>>> On Tue, Jun 5, 2012 at 1:02 PM, Bert Huijben <bert_at_qqmail.nl> wrote:
>>> >> -----Original Message-----
>>> >> From: Johan Corveleyn [mailto:jcorvel_at_gmail.com]
>>> >> Sent: dinsdag 5 juni 2012 02:00
>>> >> To: Branko ÄŒibej
>>> >> Cc: dev_at_subversion.apache.org
>>> >> Subject: Re: Failing test basic_tests.py 29 (check that repos root gets set
>>> on
>>> >> checkout)
>>> >>
>>> >> On Mon, Apr 23, 2012 at 6:11 AM, Branko ÄŒibej <brane_at_apache.org>
>>> wrote:
>>> >> > On 23.04.2012 00:00, Johan Corveleyn wrote:
>>> >> >> On Wed, Apr 18, 2012 at 7:49 AM, Daniel Shahaf <danielsh_at_elego.de>
>>> >> wrote:
>>> >> >>> Hyrum K Wright wrote on Tue, Apr 17, 2012 at 16:27:00 -0500:
>>> >> >>>> On Tue, Apr 17, 2012 at 4:05 PM, Johan Corveleyn
>>> <jcorvel_at_gmail.com>
>>> >> wrote:
>>> >> >>>>> On Tue, Apr 17, 2012 at 10:55 PM, Hyrum K Wright
>>> >> >>>>> <hyrum.wright_at_wandisco.com> wrote:
>>> >> >>>>>> On Tue, Apr 17, 2012 at 3:48 PM, Johan Corveleyn
>>> >> <jcorvel_at_gmail.com> wrote:
>>> >> >>>>>>> On Tue, Apr 17, 2012 at 10:42 AM, Philip Martin
>>> >> >>>>>>> <philip.martin_at_wandisco.com> wrote:
>>> >> >>>>>>>> Johan Corveleyn <jcorvel_at_gmail.com> writes:
>>> >> >>>>>>>>
>>> >> >>>>>>>>> Apparently, the test is comparing the 'Repository Root' from
>>> the
>>> >> >>>>>>>>> output of 'svn info' with the expected repository url. When I
>>> run
>>> >> 'svn
>>> >> >>>>>>>>> info' manually on ...\svn-test-
>>> work\working_copies\basic_tests-
>>> >> 29, I
>>> >> >>>>>>>>> see the following:
>>> >> >>>>>>>>>
>>> >> >>>>>>>>> [[[
>>> >> >>>>>>>>> Path: R:\test\subversion\tests\cmdline\svn-test-
>>> >> work\working_copies\basic_tests-29
>>> >> >>>>>>>>> Working Copy Root Path:
>>> >> >>>>>>>>> R:\test\subversion\tests\cmdline\svn-test-
>>> >> work\working_copies\basic_tests-29
>>> >> >>>>>>>>> URL: file:///R%7C/test/subversion/tests/cmdline/svn-test-
>>> >> work/local_tmp/repos
>>> >> >>>>>>>>> Repository Root:
>>> >> >>>>>>>>> file:///R%7C/test/subversion/tests/cmdline/svn-test-
>>> >> work/local_tmp/repos
>>> >> >>>>>>>>> ]]]
>>> >> >>>>>>>>>
>>> >> >>>>>>>>> So the '%7C' instead of ':' seems to be the problem (BTW,
>>> %7C is
>>> >> the
>>> >
>>> > With the 1.7+ canonicalization rules both
>>> > file:///C:/path
>>> > and
>>> > file:///C|/path
>>> > are valid urls, but only the first form is the canonical format.
>>> (svn_uri_canonicalize() will handle this, just like it updates http://host:80/dir
>>> to http://host/dir, etc.)
>>> >
>>> > Until early in Subversion 1.7 development the test suite produced the
>>> second form, while it was then updated to produce the first form.
>>
>> I just ran some tests in an attempt to confirm this behavior and the %7C form is *also* canonical in 1.7 and trunk. The '|' form is not.
>
> Ah, canonicalization. That might be it. Is it possible that with 1.7,
> svn (client) doesn't automatically canonicalize '|' to '%7C'? While on
> trunk the url is automatically canonicalized by the client?
>
> The problem seems to be that this test (basic_tests.py#30), when run
> over ra_local, executes "svn co file:///X", and then compares the URL
> (or Repos Root) from "svn info" to the original url (literal string
> comparison). Where:
>
> - With trunk, when I use python 2.6, X=R|/test/subversion/....
> However, svn (client) canonicalizes this url, so it ends up becoming
> file:///R%7C/test/subversion when asking 'svn info', so the test
> fails.
>
> - With trunk, when I use python 2.7, X=R:/test/subversion/.... This
> url is not changed by canocalization, so the test succeeds.
>
> - With 1.7 (and earlier), when I use python 2.6,
> X=R|/test/subversion/.... But there is no automatic canonicalization,
> so 'svn info' still says file:///R|/test/subversion?

No, I'm wrong: both 1.7.4 and 1.6.17 transform "svn co file:///C|/bla"
into the url "file:///C%7C/bla" (when asking 'svn info' of the checked
out wc). So when this form is used, this test (with the literal
comparison) always fails.

So the only question remaining (apart from fixing this test to be
tolerant for this canonicalization) is why (on my machine at least)
the test suite sometimes uses "|" (with python 2.6 and trunk, but not
with 1.7 or earlier), and sometimes ":" (with 1.7 or earlier, or with
trunk and python 2.7).

-- 
Johan
Received on 2012-06-05 13:59:45 CEST

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.