Sha256: 08064294154586908fd9a5c4158c86fd48d83e8b9aa70e3cf565cfc064aa50c5
Contents?: true
Size: 872 Bytes
Versions: 2
Compression:
Stored size: 872 Bytes
Contents
require 'spec_helper' describe YAML do it "should autoload classes that are unknown at runtime" do lambda { obj = YAML.load("--- !ruby/object:Autoloaded::Clazz {}") obj.class.to_s.should == 'Autoloaded::Clazz' }.should_not raise_error end it "should autoload structs that are unknown at runtime" do lambda { obj = YAML.load("--- !ruby/struct:Autoloaded::Struct {}") obj.class.to_s.should == 'Autoloaded::Struct' }.should_not raise_error end # As we're overriding some of Yaml's internals it is best that our changes # don't impact other places where Yaml is used. Or at least don't make it # look like the exception is caused by DJ it "should not raise exception on poorly formatted yaml" do lambda do YAML.load(<<-EOYAML default: <<: *login EOYAML ) end.should_not raise_error end end
Version data entries
2 entries across 2 versions & 2 rubygems
Version | Path |
---|---|
delayed_job_hooked-2.1.5 | spec/yaml_ext_spec.rb |
delayed_job-2.1.4 | spec/yaml_ext_spec.rb |