зеркало из https://github.com/github/ruby.git
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:
Родитель
1a84c07715
Коммит
96228e3ed6
|
@ -1271,8 +1271,16 @@ ruby_version_is "2.7" do
|
|||
path.should.end_with?("/etc.#{RbConfig::CONFIG['DLEXT']}")
|
||||
end
|
||||
|
||||
it "raises LoadError if feature cannot be found" do
|
||||
-> { $LOAD_PATH.resolve_feature_path('noop') }.should raise_error(LoadError)
|
||||
ruby_version_is "2.7"..."3.1" do
|
||||
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
|
||||
|
|
Загрузка…
Ссылка в новой задаче