Skip to content

Commit a894444

Browse files
committed
[GR-45010] Fix Time.new(in: zone) spec to avoid transient failures
1 parent 7958712 commit a894444

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

spec/ruby/core/time/new_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -456,7 +456,7 @@ def zone.local_to_utc(t)
456456
Time.new(2000, 1, 1, in: "+05:00").should == Time.new(2000, 1, 1, 0, 0, 0, "+05:00")
457457
Time.new(2000, 1, in: "+05:00").should == Time.new(2000, 1, 1, 0, 0, 0, "+05:00")
458458
Time.new(2000, in: "+05:00").should == Time.new(2000, 1, 1, 0, 0, 0, "+05:00")
459-
Time.new(in: "+05:00").round(0).should == Time.now.getlocal("+05:00").round(0)
459+
Time.new(in: "+05:00").tap { |time| time.should == time.getlocal("+05:00") }
460460
end
461461

462462
it "converts to a provided timezone if all the positional arguments are omitted" do

0 commit comments

Comments
 (0)