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

[PATCH] Ruby bindings client tests for diff_summarize and diff_summarize_peg

From: Joe Swatosh <joe.swatosh_at_gmail.com>
Date: 2007-08-14 07:56:55 CEST

[[[
At some point svn_client_diff_summarize2 must have changed to
not report the path if the diff requested was on a file instead of a
directory. I remember reading something like that in the docs for
a diff function somewhere, but for the life of me I can't find the
reference now.

* subversion/bindings/swig/ruby/test/test_client.rb
  (SvnClientTest#test_diff_summarize) pass the parent directory to
  Svn::Client::Context#diff_summarize instead of the actual file so
  there will be a path to summarize.
  (SvnClientTest#test_diff_summarize_peg) pass the uri of the parent
  directory to Svn::Client::Context#diff_summarize_pet instead of the
  actual file uri so there will be a path to summarize.

]]]

Index: subversion/bindings/swig/ruby/test/test_client.rb
===================================================================
--- subversion/bindings/swig/ruby/test/test_client.rb (revision 26069)
+++ subversion/bindings/swig/ruby/test/test_client.rb (working copy)
@@ -749,7 +749,7 @@
     rev2 = commit_info.revision

     diffs = []
- ctx.diff_summarize(path, rev1, path, rev2) do |diff|
+ ctx.diff_summarize(@wc_path, rev1, @wc_path, rev2) do |diff|
       diffs << diff
     end
     assert_equal([file], diffs.collect {|d| d.path})
@@ -775,7 +775,6 @@
     before_path = File.join(@wc_path, before_file)
     after_path = File.join(@wc_path, after_file)
     moved_path = File.join(@wc_path, moved_file)
- after_uri = "#{@repos_uri}/#{after_file}"

     File.open(before_path, "w") {|f| f.print(before)}

@@ -801,7 +800,7 @@
     rev5 = commit_info.revision

     diffs = []
- ctx.diff_summarize_peg(after_uri, rev3, rev4, rev3) do |diff|
+ ctx.diff_summarize_peg(@repos_uri, rev3, rev4, rev3) do |diff|
       diffs << diff
     end
     assert_equal([after_file], diffs.collect {|d| d.path})

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Received on Tue Aug 14 07:54:48 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.