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

Re: svn commit: r37873 - trunk/subversion/tests/libsvn_wc

From: Hyrum K. Wright <hyrum_at_hyrumwright.org>
Date: Thu, 28 May 2009 07:21:00 -0500

Please revert this change. As the comment you modified in r37874 says:
"Make sure SVN_DEPRECATED is defined as empty before including
svn_path.h. We don't want to trigger deprecation warnings by the
tests of those funtions."

New code will test the new APIs, but old tests should still continue
to work, even after the old APIs have been re-implemented as wrappers
around the new APIs. By leaving the deprecated function calls in the
tests, we can ensure this is still true.

The correct fix to get rid of the warning is something similar to what
is done in the other C tests for deprecated functions, by playing with
SVN_DEPRECATED so that the warning isn't generated in the first
place. I leave the exact implementation as an exercise to the
reader. :)

-Hyrum

On May 28, 2009, at 2:12 AM, Senthil Kumaran S wrote:

> Author: stylesen
> Date: Thu May 28 00:12:34 2009
> New Revision: 37873
>
> Log:
> * subversion/tests/libsvn_wc/db-test.c
> (create_fake_wc): Fix deprecated warning of 'svn_io_remove_file'
> usage.
>
> Modified:
> trunk/subversion/tests/libsvn_wc/db-test.c
>
> Modified: trunk/subversion/tests/libsvn_wc/db-test.c
> URL: http://svn.collab.net/viewvc/svn/trunk/subversion/tests/libsvn_wc/db-test.c?pathrev=37873&r1=37872&r2=37873
> =
> =
> =
> =
> =
> =
> =
> =
> ======================================================================
> --- trunk/subversion/tests/libsvn_wc/db-test.c Wed May 27 21:33:14
> 2009 (r37872)
> +++ trunk/subversion/tests/libsvn_wc/db-test.c Thu May 28 00:12:34
> 2009 (r37873)
> @@ -296,7 +296,7 @@ create_fake_wc(const char *subdir, apr_p
> svn_sqlite__db_t *sdb;
>
> SVN_ERR(svn_io_make_dir_recursively(dirpath, scratch_pool));
> - svn_error_clear(svn_io_remove_file(dbpath, scratch_pool));
> + svn_error_clear(svn_io_remove_file2(dbpath, FALSE, scratch_pool));
> SVN_ERR(svn_sqlite__open(&sdb, dbpath, svn_sqlite__mode_rwcreate,
> NULL,
> SVN_WC__VERSION,
> data_loading_sql, scratch_pool,
> scratch_pool));
>
> ------------------------------------------------------
> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=495&dsMessageId=2356054

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=2356120
Received on 2009-05-28 14:21:38 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.