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

Re: Status report for Ruby bindings on Windows

From: Joe Swatosh <joe.swatosh_at_gmail.com>
Date: 2007-02-01 06:24:30 CET

Hi kou

On 1/30/07, Kouhei Sutou <kou@cozmixng.org> wrote:
> Hi Joe,
>
> In <ae6cb1100701292301o55581b5ay5826525a743d7e20@mail.gmail.com>
> "Re: Status report for Ruby bindings on Windows" on Mon, 29 Jan 2007 23:01:59 -0800,
> "Joe Swatosh" <joe.swatosh@gmail.com> wrote:
>

>
> > * Normalizing the line breaks. Upon reflection, I've decided that I
> > started us down the wrong path when I modified the tests for the line
> > ending issues. As I've thought about it more, I now believe that the
> > bindings should do the conversions. My thinking is since Ruby treats
> > line endings as "'\n" instead of "\r\n" the bindings should provide
> > any multiline values Ruby expects. (This is where the 'b' comes from
> > when calling File::open. Without the 'b' on windows there is a \r\n
> > to \n conversion. With the 'b', no conversion. Maybe we should check
> > out what the Perl and Python bindings do about this issue on
> > windows?). (I've made zero effort to figure out what this will take).
>
> OK. We'll try the problem after we solve test environment
> problem on Windows.
>

>

Removing all invocations and the definition of normalize_line_break
from the test\*.rb files and the attached patch get us:

D:\SVN\src-trunk\subversion\bindings\swig\ruby>ruby test\run-test.rb
Loaded suite test
Started
........................................................................................F.......F......................................F...
Finished in 421.183 seconds.

  1) Failure:
test_delta(SvnFsTest)
[D:/SVN/src-trunk/subversion/bindings/swig/ruby/test/test_fs.rb:317]:
<"A\n\n\n\nE\n"> expected but was
<"<<<<<<< .mine\nA\nb\nc\nd\nE\n=======\na\n\n\n\ne\n>>>>>>> .r2\n">.

  2) Failure:
test_diff(SvnInfoTest)
[D:/SVN/src-trunk/subversion/bindings/swig/ruby/test/test_info.rb:202]:
<2> expected but was
<1>.

  3) Failure:
test_translated_file(SvnWcTest)
    [D:/SVN/src-trunk/subversion/bindings/swig/ruby/test/test_wc.rb:417:in
`test_translated_file'
     D:/SVN/src-trunk/subversion/bindings/swig/ruby/svn/wc.rb:94:in `_open'
     D:/SVN/src-trunk/subversion/bindings/swig/ruby/svn/wc.rb:73:in `open'
     D:/SVN/src-trunk/subversion/bindings/swig/ruby/test/test_wc.rb:409:in
`test_translated_file']:
<"a\r\n"> expected but was
<"a\n">.

139 tests, 893 assertions, 3 failures, 0 errors

So that fixed most of the line ending failures, but caused a
regression in test_wc.

--
Joe


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

Received on Thu Feb 1 06:24: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.