Top Level Namespace

Defined Under Namespace

Modules: Jasmine, Rack

Instance Method Summary collapse

Instance Method Details

#ruby_version_less_than(target_version) ⇒ Object



1
2
3
4
5
6
7
8
9
10
# File 'lib/jasmine/ruby_versions.rb', line 1

def ruby_version_less_than(target_version)
  version_parts = RUBY_VERSION.split('.').map(&:to_i).zip(target_version)

  version_parts.each do |(current_part, target_part)|
    if current_part < target_part
      return true
    end
  end
  false
end