File: rspec_all_versions.sh

package info (click to toggle)
ruby-pathspec 1.0.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 224 kB
  • sloc: ruby: 861; sh: 21; makefile: 8
file content (20 lines) | stat: -rwxr-xr-x 412 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/bin/bash
function testversion {
  echo Testing Ruby $1
  rbenv install -s $1
  rbenv local $1
  gem install bundler --quiet
  bundle install --quiet
  bundle exec rspec
  if [ $? -eq 0 ]; then
    echo -e "\033[32mSuccess testing Ruby $1\033[0m"
  else
    echo -e "\033[31mFailed testing Ruby $1 Exit code was $?\033[0m"
  fi
  echo

}

for VERSION in 2.2.9 2.3.6 2.4.3 2.5.0; do
  testversion $VERSION
done