File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
spec/ruby/core/kernel/shared Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change 223223 it "loads c-extension file when passed absolute path without extension when no .rb is present" do
224224 # the error message is specific to what dlerror() returns
225225 path = File . join CODE_LOADING_DIR , "a" , "load_fixture"
226- -> { @object . send ( @method , path ) } . should raise_error ( Exception , /file too short|not a mach-o file|slice is not valid mach-o file/ )
226+ -> { @object . send ( @method , path ) } . should raise_error ( LoadError )
227227 end
228228 end
229229
230230 platform_is :darwin do
231231 it "loads .bundle file when passed absolute path with .so" do
232232 # the error message is specific to what dlerror() returns
233233 path = File . join CODE_LOADING_DIR , "a" , "load_fixture.so"
234- -> { @object . send ( @method , path ) } . should raise_error ( Exception , /load_fixture \. bundle.+(file too short|not a mach-o file|slice is not valid mach-o file)/ )
234+ -> { @object . send ( @method , path ) } . should raise_error ( LoadError )
235235 end
236236 end
237237
You can’t perform that action at this time.
0 commit comments