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

Re: stat_tests.py 19 is failing?

From: Paul Burba <ptburba_at_gmail.com>
Date: Wed, 15 Dec 2010 16:38:32 -0500

On Wed, Dec 15, 2010 at 3:03 PM, C. Michael Pilato <cmpilato_at_collab.net> wrote:
> On 12/15/2010 03:00 PM, C. Michael Pilato wrote:
>> On 12/15/2010 02:58 PM, Philip Martin wrote:
>>> "C. Michael Pilato" <cmpilato_at_collab.net> writes:
>>>
>>>> On 12/15/2010 02:11 PM, Philip Martin wrote:
>>>>> "C. Michael Pilato" <cmpilato_at_collab.net> writes:
>>>>>
>>>>>> Try r1049668 -- see if stuff still passes for you in your default
>>>>>> configuration.
>>>>>
>>>>> Yes, it does.
>>>>
>>>> Cool.  Thanks.
>>>
>>> It seems to fail on Windows:
>>>
>>> http://ci.apache.org/builders/svn-slik-w2k3-x64-local/builds/2437
>>
>> Doh!  I wonder if this would do the trick:
>>
>> Index: subversion/tests/cmdline/stat_tests.py
>> ===================================================================
>> --- subversion/tests/cmdline/stat_tests.py    (revision 1049668)
>> +++ subversion/tests/cmdline/stat_tests.py    (working copy)
>> @@ -964,7 +964,7 @@
>>    "status on unversioned dir (issue 2030)"
>>    sbox.build(read_only = True)
>>    dir = sbox.repo_dir
>> -  expected_err = "svn: warning: '.*/" + os.path.basename(dir) + \
>> +  expected_err = "svn: warning: '.*" + os.sep + os.path.basename(dir) + \
>>                   "' is not a working copy"
>>    svntest.actions.run_and_verify_svn2(None, [], expected_err, 0,
>>                                        "status", dir, dir)
>>
>
> Or would that backslash need to be escaped?  *grumble*...

It would, this fails on Windows as you suspected:

EXPECTED STDERR (regexp):
svn: warning: '.*\repos' is not a working copy
ACTUAL STDERR:
svn: warning: 'C:\SVN\src-trunk\Release\subversion\tests\cmdline\svn-test-work\local_tmp\repos'
is not a working copy
svn: warning: 'C:\SVN\src-trunk\Release\subversion\tests\cmdline\svn-test-work\local_tmp\repos'
is not a working copy

IIRC you actually need to escape the escape character here, like this
(warning, be prepared for ugly):

expected_err = "svn: warning: '.*(/|\\\\)" + os.path.basename(dir) + \
                 "' is not a working copy"

I suspect there is a prettier way to do it, but maybe not.

Paul
Received on 2010-12-15 22:39:10 CET

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.