diff options
author | Benoit Daloze <[email protected]> | 2019-09-29 19:13:37 +0200 |
---|---|---|
committer | Benoit Daloze <[email protected]> | 2019-09-29 19:13:37 +0200 |
commit | 070cbe22b70ec2bec36c7cfc84b726510afa306f (patch) | |
tree | 56cee87834c85bd9f358ebee51bab4893fb9952f /spec/ruby/core/kernel | |
parent | d51b4e34fbdbe1a845aa2251b1fa3304de809b32 (diff) |
Update to ruby/spec@34e6246
Diffstat (limited to 'spec/ruby/core/kernel')
-rw-r--r-- | spec/ruby/core/kernel/caller_locations_spec.rb | 2 | ||||
-rw-r--r-- | spec/ruby/core/kernel/shared/require.rb | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/spec/ruby/core/kernel/caller_locations_spec.rb b/spec/ruby/core/kernel/caller_locations_spec.rb index 03c05883d1..4de6c2ffd6 100644 --- a/spec/ruby/core/kernel/caller_locations_spec.rb +++ b/spec/ruby/core/kernel/caller_locations_spec.rb @@ -13,7 +13,7 @@ describe 'Kernel#caller_locations' do it 'returns an Array of caller locations using a custom offset' do locations = KernelSpecs::CallerLocationsTest.locations(2) - locations[0].absolute_path.end_with?('mspec.rb').should == true + locations[0].absolute_path.should.end_with?('mspec.rb') end it 'returns an Array of caller locations using a custom limit' do diff --git a/spec/ruby/core/kernel/shared/require.rb b/spec/ruby/core/kernel/shared/require.rb index cfa1a4bbbd..52089f22fe 100644 --- a/spec/ruby/core/kernel/shared/require.rb +++ b/spec/ruby/core/kernel/shared/require.rb @@ -20,7 +20,7 @@ describe :kernel_require_basic, shared: true do it "raises a LoadError if the file does not exist" do path = File.expand_path "nonexistent.rb", CODE_LOADING_DIR - File.exist?(path).should be_false + File.should_not.exist?(path) -> { @object.send(@method, path) }.should raise_error(LoadError) ScratchPad.recorded.should == [] end @@ -41,7 +41,7 @@ describe :kernel_require_basic, shared: true do end it "raises a LoadError" do - File.exist?(@path).should be_true + File.should.exist?(@path) -> { @object.send(@method, @path) }.should raise_error(LoadError) end end @@ -247,7 +247,7 @@ describe :kernel_require, shared: true do describe "(file extensions)" do it "loads a .rb extensioned file when passed a non-extensioned path" do path = File.expand_path "load_fixture", CODE_LOADING_DIR - File.exist?(path).should be_true + File.should.exist?(path) @object.require(path).should be_true ScratchPad.recorded.should == [:loaded] end @@ -271,7 +271,7 @@ describe :kernel_require, shared: true do it "loads a .rb extensioned file when passed a non-.rb extensioned path" do path = File.expand_path "load_fixture.ext", CODE_LOADING_DIR - File.exist?(path).should be_true + File.should.exist?(path) @object.require(path).should be_true ScratchPad.recorded.should == [:loaded] end |