Skip to content
This repository was archived by the owner on Nov 30, 2024. It is now read-only.

Commit dbb5271

Browse files
committed
Remove require 'time'
1 parent bc88419 commit dbb5271

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

spec/rspec/core/ordering_spec.rb

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -82,11 +82,9 @@ def order_with(seed)
8282
end
8383

8484
RSpec.describe ModificationTime do
85-
require 'time'
86-
8785
before do
88-
allow(File).to receive(:mtime).with('./file_1.rb').and_return(::Time.parse('18:00'))
89-
allow(File).to receive(:mtime).with('./file_2.rb').and_return(::Time.parse('18:01'))
86+
allow(File).to receive(:mtime).with('./file_1.rb').and_return(::Time.new)
87+
allow(File).to receive(:mtime).with('./file_2.rb').and_return(::Time.new + 1)
9088
end
9189

9290
it 'orders list by file modification time' do

0 commit comments

Comments
 (0)