Re: [PATCH 1/2] git-svn.perl: perform deletions before anything else
- From
Steven Walter <stevenrwalter@gmail.com>
- Date
- Feb 15, 2012, 17:47 UTC
- Message-ID
- <CAK8d-a+tdK=Jn6D+X=bJmKTzbESPqd8+S2nJr9_sfdb7MhLN1A@mail.gmail.com>
- In-Reply-To
- <20120212234928.GA4513@dcvr.yhbt.net>
On Sun, Feb 12, 2012 at 6:49 PM, Eric Wong <normalperson@yhbt.net> wrote:
Show 13 quoted lines
> Steven Walter <stevenrwalter@gmail.com> wrote: >> On Sun, Feb 12, 2012 at 2:03 AM, Eric Wong <normalperson@yhbt.net> wrote: >> > Steven Walter <stevenrwalter@gmail.com> wrote: >> >> Signed-off-by: Steven Walter <stevenrwalter@gmail.com> >> > >> > Thanks, shall I fixup 2/2 and assume you meant to Sign-off on that, too? >> >> Yes, thanks > > Ugh, I got a bunch of test failures on t9100-git-svn-basic.sh with your > updated 1/2 and a trivially merged 2/2: > > not ok - 7 detect node change from file to directory #2
I believe that "test_must_fail" is incorrect for this case. "git svn set-tree" is succeeding, and the git commit is being faithfully recorded into the svn repository. If svn will allow us to do it, then I don't think git-svn should artificially fail in the case. This is using svn 1.6.17
What's the oldest version of svn supported by git-svn? Perhaps if I retry with that version of svn, I would see a failure. However, if libsvn-perl reports the failure correctly, isn't that good enough behavior? No need to fail in git-svn before even trying, IMHO.
> not ok - 12 new symlink is added to a file that was also just made executable > not ok - 13 modify a symlink to become a file > not ok - 14 commit with UTF-8 message: locale: en_US.UTF-8 > not ok - 16 check imported tree checksums expected tree checksums
The rest of these problems seem to have been cascading failures resulting from the unexpected success of "git svn set-tree" in test 7. This left the git and svn repositories in a different state. To get these to pass, I changed later references to "bar/zzz" (which is now a directory) to use "file" instead. I also had to update the expected checksum values for test 16. Is there a way to validate what the checksums should be, other than to look at it and say, "yup, the trees look okay?"
> I would very much appreciate new test cases that can show exactly what's > fixed by your patches (esp given the only times I run/use git-svn is > when reviewing patches). Thanks!.
In fact test 7 is exactly what I was trying to make work. The fact that "git svn set-tree" now succeeds in that case is proof that my change had the desired effect. I modified test 7 to verify that set-tree succeeds and that bar/zzz and bar/zzz/yyy get created in $SVN_TREE.
Assuming you agree with the above analysis, should I squash the test changes into my 2/2, or would you prefer a separate patch?
-- -Steven Walter <stevenrwalter@gmail.com>