> From: Greg Stein [mailto:gstein@lyra.org]
> Sent: Friday, January 10, 2003 12:33 AM
> Here is a fun test:
>
> * write a simple C wrapper to produce a simple style of diff
> * write a tool that:
> - chooses two files at random [from one or more source trees would be an
> easy input set]
> - diff them using 'diff' and using the wrapper
> - compare the output; log an error if different
> - repeat
>
> Feed it the httpd or SVN or whatever source tree for ample input, let it run
> for a few hours or ten, and see what happens.
>
> Hmm. I guess two the tools could select different add/delete sections, huh?
> So now I see why Sander suggested the "patch" route. Well, the iteration
> still works.
Indeed. Any takers? The simple C wrappers, diff-test and diff3-test, can be
found in subversion/test/libsvn_delta/, after a normal build.
> The second followup is how to get source material that is a bit closer match
> to each other, so that the diff won't report "the whole file" as changed.
> Then it gets a bit tougher. Maybe have the tool run 'svn log -q FILE' to get
> a set of changed revs for a file, pick two, fetch them, and run the test.
Actually, just walking through history would do the trick:
- checkout at rev 1
- save the files that have changed in the next rev
- update to the next rev
- diff the saved files against their new revision
- patch the saved files and compare against the new revision
- repeat until rev == HEAD.
Sander
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Tue Jan 14 21:32:37 2003