josephholsten / rets4r

Bringing RETS to ruby
MIT License
52 stars 28 forks source link

FIXED: build failures on 1.9.1, 1.9.2, HEAD #20

Closed jschairb closed 13 years ago

jschairb commented 13 years ago

Item 1

1.9.2 String no longer includes Enumberable so a method that returns an Enumerble has to be added

Fixes the following:

1) Error:
test_login_results(RETS4R::Client::TestParser):
NoMethodError: undefined method `map' for #<String:0x00000001ce4018>
    /tmp/travis/builds/josephholsten/rets4r/lib/rets4r/response_document/base.rb:121:in `to_h'
    /tmp/travis/builds/josephholsten/rets4r/lib/rets4r/response_document/base.rb:113:in `block in parse_key_value'
    /tmp/travis/builds/josephholsten/rets4r/lib/rets4r/response_document/base.rb:135:in `block in to_transaction'
    /tmp/travis/builds/josephholsten/rets4r/lib/rets4r/response_document/base.rb:130:in `tap'
    /tmp/travis/builds/josephholsten/rets4r/lib/rets4r/response_document/base.rb:130:in `to_transaction'
    /tmp/travis/builds/josephholsten/rets4r/lib/rets4r/response_document/base.rb:113:in `parse_key_value'
    /tmp/travis/builds/josephholsten/rets4r/lib/rets4r/client/parsers/response_parser.rb:5:in `parse_key_value'
    test/test_parser.rb:29:in `parse_to_transaction'
    test/test_parser.rb:82:in `test_login_results'
    /home/travis/.rvm/gems/ruby-1.9.2-p180/gems/mocha-0.9.12/lib/mocha/integration/mini_test/version_142_to_172.rb:27:in `run'

Item 2

Removed text-only files from code quality tests

Fixes the following

  1) Error:
test_has_no_malformed_whitespace(TestQuality):
ArgumentError: invalid byte sequence in UTF-8
    test/test_quality.rb:36:in `block in check_for_tab_characters'
    test/test_quality.rb:35:in `each'
    test/test_quality.rb:35:in `each_with_index'
    test/test_quality.rb:35:in `check_for_tab_characters'
    test/test_quality.rb:22:in `block (2 levels) in test_has_no_malformed_whitespace'
    test/test_quality.rb:19:in `each'
    test/test_quality.rb:19:in `block in test_has_no_malformed_whitespace'
    test/test_quality.rb:18:in `chdir'
    test/test_quality.rb:18:in `test_has_no_malformed_whitespace'
    /Users/jschairb/.rvm/gems/ruby-1.9.2-p180@rets4r/gems/mocha-0.9.12/lib/mocha/integration/mini_test/version_142_to_172.rb:27:in `run'

Item 3

I'll be honest, I don't completely understand why requiring has changed in 1.9.2, but requiring by the full filename seems to work better.

Fixes the following:

1) Failure:
test test/test_helper.rb(TestIsolated) [test/ts_isolated.rb:15]:
Expected block to return true value.

Item 4

This doesn't "fix" anything per se, there were no failing specs, although I think that's probably because of a lack of coverage. 1.9.2 was erroring when trying to authenticate because it could not find the RETS4R::Auth class. I added the require to rets4r.rb.