зеркало из https://github.com/github/ruby.git
Update to ruby/spec@b8a8240
This commit is contained in:
Родитель
b5358a98e6
Коммит
1315c5aad9
|
@ -3,7 +3,7 @@ describe :dir_chroot_as_root, shared: true do
|
|||
DirSpecs.create_mock_dirs
|
||||
|
||||
@real_root = "../" * (File.dirname(__FILE__).count('/') - 1)
|
||||
@ref_dir = File.join("/", Dir.new('/').entries.first)
|
||||
@ref_dir = File.join("/", File.basename(Dir["/*"].first))
|
||||
end
|
||||
|
||||
after :all do
|
||||
|
|
|
@ -17,10 +17,9 @@ describe :env_update, shared: true do
|
|||
|
||||
ruby_version_is "3.2" do
|
||||
it "adds the multiple parameter hashes to ENV, returning ENV" do
|
||||
ENV.send(@method, {"foo" => "0", "bar" => "1"}, {"baz" => "2"}).should equal(ENV)
|
||||
ENV["foo"].should == "0"
|
||||
ENV["bar"].should == "1"
|
||||
ENV["baz"].should == "2"
|
||||
ENV.send(@method, {"foo" => "multi1"}, {"bar" => "multi2"}).should equal(ENV)
|
||||
ENV["foo"].should == "multi1"
|
||||
ENV["bar"].should == "multi2"
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
@ -18,7 +18,8 @@ describe "DateTime#to_time" do
|
|||
time.sec.should == 59
|
||||
end
|
||||
|
||||
version_is(Date::VERSION, '3.2.3') do
|
||||
date_version = defined?(Date::VERSION) ? Date::VERSION : '0.0.0'
|
||||
version_is(date_version, '3.2.3') do
|
||||
it "returns a Time representing the same instant before Gregorian" do
|
||||
datetime = DateTime.civil(1582, 10, 4, 23, 58, 59)
|
||||
time = datetime.to_time.utc
|
||||
|
|
|
@ -13,7 +13,8 @@ describe "Time#to_datetime" do
|
|||
datetime.sec.should == 59
|
||||
end
|
||||
|
||||
version_is(Date::VERSION, '3.2.3') do
|
||||
date_version = defined?(Date::VERSION) ? Date::VERSION : '0.0.0'
|
||||
version_is(date_version, '3.2.3') do
|
||||
it "returns a DateTime representing the same instant before Gregorian" do
|
||||
time = Time.utc(1582, 10, 14, 23, 58, 59)
|
||||
datetime = time.to_datetime
|
||||
|
|
Загрузка…
Ссылка в новой задаче