Merge pull request #9102 from briancain/RUBY-24
Introduce Ruby 2.4 to Vagrant
This commit is contained in:
commit
89f8c31c76
|
@ -10,8 +10,8 @@ addons:
|
|||
- bsdtar
|
||||
|
||||
rvm:
|
||||
- 2.2.5
|
||||
- 2.3.3
|
||||
- 2.3.5
|
||||
- 2.4.2
|
||||
|
||||
branches:
|
||||
only:
|
||||
|
|
|
@ -45,7 +45,7 @@ module Vagrant
|
|||
result = 1
|
||||
end
|
||||
|
||||
result = 0 if !result.is_a?(Fixnum)
|
||||
result = 0 if !result.is_a?(Integer)
|
||||
return result
|
||||
end
|
||||
|
||||
|
|
|
@ -50,7 +50,7 @@ module Vagrant
|
|||
# until then. It will wait up to the given duration or raise an
|
||||
# exception if something goes wrong.
|
||||
#
|
||||
# @param [Fixnum] duration Timeout in seconds.
|
||||
# @param [Integer] duration Timeout in seconds.
|
||||
# @return [Boolean] Will return true on successful connection
|
||||
# or false on timeout.
|
||||
def wait_for_ready(duration)
|
||||
|
|
|
@ -52,7 +52,7 @@ module Vagrant
|
|||
|
||||
# Return the number of elements in this registry.
|
||||
#
|
||||
# @return [Fixnum]
|
||||
# @return [Integer]
|
||||
def length
|
||||
@items.keys.length
|
||||
end
|
||||
|
|
|
@ -26,7 +26,7 @@ module Vagrant
|
|||
private_key = rsa_key.to_pem
|
||||
|
||||
if password
|
||||
cipher = OpenSSL::Cipher::Cipher.new('des3')
|
||||
cipher = OpenSSL::Cipher.new('des3')
|
||||
private_key = rsa_key.to_pem(cipher, password)
|
||||
end
|
||||
|
||||
|
|
|
@ -106,10 +106,10 @@ module VagrantPlugins
|
|||
def args_valid?
|
||||
return true if !args
|
||||
return true if args.is_a?(String)
|
||||
return true if args.is_a?(Fixnum)
|
||||
return true if args.is_a?(Integer)
|
||||
if args.is_a?(Array)
|
||||
args.each do |a|
|
||||
return false if !a.kind_of?(String) && !a.kind_of?(Fixnum)
|
||||
return false if !a.kind_of?(String) && !a.kind_of?(Integer)
|
||||
end
|
||||
|
||||
return true
|
||||
|
|
|
@ -63,10 +63,10 @@ module VagrantPlugins
|
|||
def args_valid?
|
||||
return true if !args
|
||||
return true if args.is_a?(String)
|
||||
return true if args.is_a?(Fixnum)
|
||||
return true if args.is_a?(Integer)
|
||||
if args.is_a?(Array)
|
||||
args.each do |a|
|
||||
return false if !a.kind_of?(String) && !a.kind_of?(Fixnum)
|
||||
return false if !a.kind_of?(String) && !a.kind_of?(Integer)
|
||||
end
|
||||
|
||||
return true
|
||||
|
|
|
@ -30,7 +30,7 @@ describe "VagrantPlugins::Shell::Config" do
|
|||
expect(result["shell provisioner"]).to eq([])
|
||||
end
|
||||
|
||||
it "passes with fixnum args" do
|
||||
it "passes with integer args" do
|
||||
subject.path = file_that_exists
|
||||
subject.args = 1
|
||||
subject.finalize!
|
||||
|
@ -112,7 +112,7 @@ describe "VagrantPlugins::Shell::Config" do
|
|||
end
|
||||
|
||||
describe 'finalize!' do
|
||||
it 'changes fixnum args into strings' do
|
||||
it 'changes integer args into strings' do
|
||||
subject.path = file_that_exists
|
||||
subject.args = 1
|
||||
subject.finalize!
|
||||
|
@ -120,7 +120,7 @@ describe "VagrantPlugins::Shell::Config" do
|
|||
expect(subject.args).to eq '1'
|
||||
end
|
||||
|
||||
it 'changes fixnum args in arrays into strings' do
|
||||
it 'changes integer args in arrays into strings' do
|
||||
subject.path = file_that_exists
|
||||
subject.args = ["string", 1, 2]
|
||||
subject.finalize!
|
||||
|
|
|
@ -70,7 +70,7 @@ describe VagrantPlugins::LocalExecPush::Config do
|
|||
expect(errors).to be_empty
|
||||
end
|
||||
|
||||
it "passes with fixnum args" do
|
||||
it "passes with integer args" do
|
||||
subject.args = 1
|
||||
expect(errors).to be_empty
|
||||
end
|
||||
|
@ -118,7 +118,7 @@ describe VagrantPlugins::LocalExecPush::Config do
|
|||
expect(errors).to be_empty
|
||||
end
|
||||
|
||||
it "passes with fixnum args" do
|
||||
it "passes with integer args" do
|
||||
subject.args = 1
|
||||
expect(errors).to be_empty
|
||||
end
|
||||
|
|
|
@ -12,7 +12,7 @@ Gem::Specification.new do |s|
|
|||
s.summary = "Build and distribute virtualized development environments."
|
||||
s.description = "Vagrant is a tool for building and distributing virtualized development environments."
|
||||
|
||||
s.required_ruby_version = "~> 2.2", "< 2.4"
|
||||
s.required_ruby_version = "~> 2.2", "< 2.5"
|
||||
s.required_rubygems_version = ">= 1.3.6"
|
||||
s.rubyforge_project = "vagrant"
|
||||
|
||||
|
@ -43,7 +43,7 @@ Gem::Specification.new do |s|
|
|||
s.add_development_dependency "rake", "~> 12.0.0"
|
||||
s.add_development_dependency "rspec", "~> 3.5.0"
|
||||
s.add_development_dependency "rspec-its", "~> 1.2.0"
|
||||
s.add_development_dependency "webmock", "~> 1.20"
|
||||
s.add_development_dependency "webmock", "~> 2.3.1"
|
||||
s.add_development_dependency "fake_ftp", "~> 0.1.1"
|
||||
|
||||
# The following block of code determines the files that should be included
|
||||
|
|
Loading…
Reference in New Issue