mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Fix a spec failure
http://ci.rvm.jp/logfiles/brlog.trunk-test.20210216-182358 ``` 1) $LOAD_PATH.resolve_feature_path raises LoadError if feature cannot be found FAILED Expected LoadError but no exception was raised (nil was returned) /tmp/ruby/v3/src/trunk-test/spec/ruby/language/predefined_spec.rb:1275:in `block (3 levels) in <top (required)>' /tmp/ruby/v3/src/trunk-test/spec/ruby/language/predefined_spec.rb:1259:in `block in <top (required)>' /tmp/ruby/v3/src/trunk-test/spec/ruby/language/predefined_spec.rb:1258:in `<top (required)>' ```
This commit is contained in:
parent
1a84c07715
commit
96228e3ed6
1 changed files with 10 additions and 2 deletions
|
@ -1271,8 +1271,16 @@ ruby_version_is "2.7" do
|
||||||
path.should.end_with?("/etc.#{RbConfig::CONFIG['DLEXT']}")
|
path.should.end_with?("/etc.#{RbConfig::CONFIG['DLEXT']}")
|
||||||
end
|
end
|
||||||
|
|
||||||
it "raises LoadError if feature cannot be found" do
|
ruby_version_is "2.7"..."3.1" do
|
||||||
-> { $LOAD_PATH.resolve_feature_path('noop') }.should raise_error(LoadError)
|
it "raises LoadError if feature cannot be found" do
|
||||||
|
-> { $LOAD_PATH.resolve_feature_path('noop') }.should raise_error(LoadError)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
ruby_version_is "3.1" do
|
||||||
|
it "return nil if feature cannot be found" do
|
||||||
|
$LOAD_PATH.resolve_feature_path('noop').should be_nil
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue