Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add TruffleRuby to the list of known Ruby versions #37

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion lib/ruby_dep/ruby_version.rb
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,11 @@ def recommended(status)
'2.3.0' => :unknown, # jruby-9.1.2.0, jruby-9.1.0.0
'2.2.3' => :buggy, # jruby-9.0.5.0
'2.2.0' => :insecure
}
},

'truffleruby' => {
'2.4.4' => :unknown,
},
}.freeze

def info
Expand Down
20 changes: 20 additions & 0 deletions spec/lib/ruby_dep/ruby_version_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,16 @@
subject { described_class.new('2.3.0', 'jruby') }
specify { expect(subject).to be_recognized }
end

context 'with truffleruby 1.0.0-rc2' do
subject { described_class.new('2.4.4', 'truffleruby') }
specify { expect(subject).to be_recognized }
end

context 'with a recent truffleruby' do
subject { described_class.new('2.6.1', 'truffleruby') }
specify { expect(subject).to be_recognized }
end
end

describe '#status' do
Expand Down Expand Up @@ -59,5 +69,15 @@
subject { described_class.new('9.8.7', 'ruby') }
specify { expect(subject.status).to eq(:unknown) }
end

context 'with truffleruby 1.0.0-rc2' do
subject { described_class.new('2.4.4', 'truffleruby') }
specify { expect(subject.status).to eq(:unknown) }
end

context 'with a recent truffleruby' do
subject { described_class.new('2.6.1', 'truffleruby') }
specify { expect(subject.status).to eq(:unknown) }
end
end
end