travis-test.sh 699 B

12345678910111213141516171819202122232425262728
  1. #!/usr/bin/env bash
  2. # Exit on any error.
  3. set -e
  4. test_version() {
  5. version=$1
  6. if [ "$version" == "jruby" ] ; then
  7. # No conformance tests yet -- JRuby is too broken to run them.
  8. bash --login -c \
  9. "rvm install $version && rvm use $version && \
  10. which ruby && \
  11. gem install bundler && bundle && \
  12. rake test"
  13. else
  14. bash --login -c \
  15. "rvm install $version && rvm use $version && \
  16. which ruby && \
  17. gem install bundler && bundle && \
  18. rake test"
  19. # TODO(xiaofeng): Conformance tests are disabled because the ruby testee
  20. # program crashes on some inputs.
  21. # cd ../conformance && \
  22. # make test_ruby
  23. fi
  24. }
  25. test_version $1