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

Re: svn commit: r29600 - in trunk/subversion: svnsync tests/cmdline

From: David Glasser <glasser_at_davidglasser.net>
Date: Tue, 26 Feb 2008 11:23:11 -0800

On Tue, Feb 26, 2008 at 11:09 AM, <epg_at_tigris.org> wrote:
> Author: epg
> Date: Tue Feb 26 11:09:37 2008
> New Revision: 29600
>
> Log:
> r26470 changed all the subcommand batons to a shared implementation, with
> each baton now allocated from a pool rather than on the stack, but
> copy_revprops_cmd still passed the *address* of baton. To help prevent
> such errors in the future, how about some type checking and testing?

> Modified: trunk/subversion/tests/cmdline/svnsync_tests.py
> URL: http://svn.collab.net/viewvc/svn/trunk/subversion/tests/cmdline/svnsync_tests.py?pathrev=29600&r1=29599&r2=29600
> ==============================================================================
> --- trunk/subversion/tests/cmdline/svnsync_tests.py (original)
> +++ trunk/subversion/tests/cmdline/svnsync_tests.py Tue Feb 26 11:09:37 2008
> @@ -65,6 +65,26 @@
> # should be: ['Committed revision 1.\n', 'Committed revision 2.\n']
> raise SVNUnexpectedStdout("Missing stdout")
>
> +def run_copy_revprops(url, expected_error=None):
> + "Copy revprops to the mirror repository from the master"
> + output, errput = svntest.main.run_svnsync(
> + "copy-revprops", url,
> + "--username", svntest.main.wc_author,
> + "--password", svntest.main.wc_passwd)
> + if errput:
> + if expected_error is None:
> + raise SVNUnexpectedStderr(errput)
> + else:
> + expected_error = svntest.verify.RegexOutput(expected_error,
> + match_all=False)
> + svntest.verify.compare_and_display_lines(None, "STDERR",
> + expected_error, errput)
> + elif expected_error is not None:
> + raise SVNExpectedStderr
> + if not output and not expected_error:
> + # should be: ['Committed revision 1.\n', 'Committed revision 2.\n']

No it shouldn't.

> + raise SVNUnexpectedStdout("Missing stdout")
> +
> def run_init(dst_url, src_url):
> "Initialize the mirror repository from the master"
> output, errput = svntest.main.run_svnsync(
> @@ -112,6 +132,7 @@
> run_init(dest_sbox.repo_url, repo_url)
>
> run_sync(dest_sbox.repo_url)
> + run_copy_revprops(dest_sbox.repo_url)
>
> # Remove some SVNSync-specific housekeeping properties from the
> # mirror repository in preparation for the comparison dump.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: svn-unsubscribe_at_subversion.tigris.org
> For additional commands, e-mail: svn-help_at_subversion.tigris.org
>
>

--dave

-- 
David Glasser | glasser@davidglasser.net | http://www.davidglasser.net/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: dev-help_at_subversion.tigris.org
Received on 2008-02-26 20:23:22 CET

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