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

Re: svn commit: r28378 - trunk/subversion/tests/cmdline

From: David Glasser <glasser_at_davidglasser.net>
Date: 2007-12-11 01:39:48 CET

On Dec 10, 2007 1:42 PM, <dlr@tigris.org> wrote:
> Author: dlr
> Date: Mon Dec 10 13:42:01 2007
> New Revision: 28378
>
> Log:
> Add test for issue #3039, "'update -N' on a path to be deleted
> corrupts working copy".
>
> * subversion/tests/cmdline/depth_tests.py
> (depthy_update_above_dir_to_be_deleted): Add new test case.
> (test_list): Add new test case to list, currently XFAIL.
>
> Found by: Eric Miller

Nice test, Dan! I like how you abstracted out the repeated elements;
for once I can actually read the test and convince myself that it's
correct.

Do you think it's worth also testing the variants where "A" is the
target of the update?

> + for depth in sbox_for_depth.keys():
> + wc_dir = sbox_for_depth[depth].wc_dir
> + (expected_output_func, expected_disk, expected_status_func) = \
> + expected_trees_for_depth[depth]
> + #print depth
> + svntest.actions.run_and_verify_update(wc_dir,
> + expected_output_func(wc_dir),
> + expected_disk,
> + expected_status_func(wc_dir),
> + None, None, None, None, None,
> + False,
> + "--depth=%s" % depth, wc_dir)

As a tiny python style thing here, I might have written

for depth, sbox in sbox_for_depth.iteritems():

... though maybe we never quite decided that requiring 2.2 for the
test suite is OK.

--dave

-- 
David Glasser | glasser_at_davidglasser.net | http://www.davidglasser.net/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Tue Dec 11 01:39:57 2007

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.