postmodern / chruby

Changes the current Ruby
MIT License
2.86k stars 190 forks source link

tests are not always able to download ruby #335

Open x-yuri opened 9 years ago

x-yuri commented 9 years ago

First, there doesn't always exist dir for some particular distribution release, like debian-7,8 (which I need now). And there doesn't always exist ruby for that particular release, like 2.0.0-p353 for squeeze. So, why don't we turn system_version into array? Turning test_ruby_patchlevel into array must be a hassle, but you might consider switching to 247... er, which is not available for jessie, so doesn't sound right. But then again, we can download whatever patchlevel available, and set test_ruby_patchlevel=$(ls test/opt/rubies | sed -E 's/.*p([0-9]+)/\1/'), can't we?

postmodern commented 9 years ago

So we used some code from RVM to detect the arch, OS, distro, and then download the precompiled ruby for said platform. Unfortunately, rvm-binary doesn't always have the most complete coverage.

x-yuri commented 9 years ago

So, why do we decide which version to use before knowing it's there? Why don't we download whatever ruby version available?

postmodern commented 9 years ago

The tests depend on knowing a specific version. Usually, rvm-binary has decent coverage for recent ruby versions. If you're platform isn't supported, open an issue with them and they'll look into it.

deivid-rodriguez commented 9 years ago

I just run into the same problem. Using Linux Mint and there's no binaries for it. In that case, defaulting to ubuntu works fine I think.