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

Re: svn commit: r1053130 - /subversion/trunk/subversion/tests/libsvn_subr/error-test.c

From: Blair Zajac <blair_at_orcaware.com>
Date: Mon, 27 Dec 2010 11:39:27 -0800

On 12/27/10 11:32 AM, Daniel Shahaf wrote:
> blair_at_apache.org wrote on Mon, Dec 27, 2010 at 18:36:46 -0000:
>> Author: blair
>> Date: Mon Dec 27 18:36:46 2010
>> New Revision: 1053130
>>
>> URL: http://svn.apache.org/viewvc?rev=1053130&view=rev
>> Log:
>> Have the svn_error_purge_tracing() unit test makes some real tracing
>> links so that svn_error_purge_tracing() can be properly tested, the
>> error links in the current code are not tracing links.
>>
>> * subversion/tests/libsvn_subr/error-test.c
>> (test_error_purge_tracing):
>> Use svn_error_return() to create tracing errors.
>>
>> Modified:
>> subversion/trunk/subversion/tests/libsvn_subr/error-test.c
>>
>> Modified: subversion/trunk/subversion/tests/libsvn_subr/error-test.c
>> URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/tests/libsvn_subr/error-test.c?rev=1053130&r1=1053129&r2=1053130&view=diff
>> ==============================================================================
>> --- subversion/trunk/subversion/tests/libsvn_subr/error-test.c (original)
>> +++ subversion/trunk/subversion/tests/libsvn_subr/error-test.c Mon Dec 27 18:36:46 2010
>> @@ -90,12 +90,18 @@ test_error_purge_tracing(apr_pool_t *poo
>> "SVN_NO_ERROR after being passed a "
>> "SVN_NO_ERROR.");
>>
>> - err = svn_error_quick_wrap(svn_error_create(SVN_ERR_BASE, NULL,
>> - "root error"),
>> - "wrapped");
>> - err = svn_error_quick_wrap(svn_error_create(SVN_ERR_BASE, err,
>> - "other error"),
>> - "re-wrapped");
>> + err = svn_error_return(svn_error_create(SVN_ERR_BASE, NULL, "root error"));
>> + if (! svn_error__is_tracing_link(err))
>> + {
>
> Good catch that the preexisting code was buggy, but isn't this test
> going to fail in non-maintainer mode? (because when SVN_ERR__TRACING
> isn't defined, svn_error_return() won't add the tracing wrapper link)

That's right, thanks. And we don't have SVN_ERR__TRACED either, so we couldn't
manually build one. I'll update the code.

Blair
Received on 2010-12-27 20:40: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.