everypolitician / everypolitician-ruby

Ruby gem for easy access to EveryPolitician data
http://everypolitician.org/
MIT License
14 stars 5 forks source link

Get the tests passing on the latest Ruby versions #80

Closed chrismytton closed 6 years ago

chrismytton commented 6 years ago

I was seeing some test failures when running on the latest Ruby with the most recent compatible gems.

  1. require_all 2.0.0 has been released, and breaks the tests, so I've specified that we need a version less than 2 in the gemspec updated to the latest version of everypolitician-popolo, see https://github.com/everypolitician/everypolitician-ruby/pull/80#issuecomment-429258668.
  2. Tests were failing for WebMock under Ruby 2.5, updating to the latest version fixed that.

I've also updated the Travis config to test on the latest Ruby versions.

Fixes https://github.com/everypolitician/everypolitician-ruby/issues/79

tmtmtmtm commented 6 years ago

@chrismytton Thanks for this! I'm assuming, though, that the error under 2.0.0+ is due to the new default 'strict mode' (https://github.com/jarmo/require_all/pull/21)? If so I strongly suspect it would be better to find and fix the underlying problem than to essentially disable that check by forcing an earlier version.

Or is there something else going on here?

tmtmtmtm commented 6 years ago

@chrismytton the circular requirements problem in everypolitician-popolo was fixed in https://github.com/everypolitician/everypolitician-popolo/commit/2ba8bf6b, but version 0.9 was never pushed to rubygems.

I've pushed that today, and with an update to that version here, the requirement for require_all <2.0 vanishes.

chrismytton commented 6 years ago

@tmtmtmtm Great! That seems to work for me locally, so I've pushed an updated commit which bumps the everypolitician-popolo version, rather than pinning require_all.