spec/twitter/meta_spec.rb in twitter4r-0.1.1 vs spec/twitter/meta_spec.rb in twitter4r-0.2.0

- old
+ new

@@ -21,29 +21,28 @@ end end describe "Twitter::Meta cache policy" do include ERBMetaMixin - include ERBMetaMixin before(:each) do @root_dir = project_root_dir @meta = Twitter::Meta.new(@root_dir) @expected_pkg_info = load_erb_yaml(File.join(@root_dir, 'pkg-info.yml'), binding) @expected_project_files = project_files @expected_spec_files = spec_files end it "should store value returned from project_files in @project_files after first glob" do - @meta.instance_eval("@project_files").should be(nil) + @meta.instance_eval("@project_files").should eql(nil) @meta.project_files @meta.instance_eval("@project_files").should eql(@expected_project_files) @meta.project_files @meta.instance_eval("@project_files").should eql(@expected_project_files) end it "should store value returned from spec_files in @spec_files after first glob" do - @meta.instance_eval("@spec_files").should be(nil) + @meta.instance_eval("@spec_files").should eql(nil) @meta.spec_files @meta.instance_eval("@spec_files").should eql(@expected_spec_files) @meta.spec_files @meta.instance_eval("@spec_files").should eql(@expected_spec_files) end @@ -81,9 +80,11 @@ it "should return Gem specification based on YAML file contents and #project_files and #spec_files return values" do spec = @meta.gem_spec expected_spec_hash = @expected_yaml_hash['spec'] expected_spec_hash.each do |key, val| - spec.send(key).should.eql? expected_spec_hash[key] + unless val.is_a?(Hash) + spec.send(key).should.eql? expected_spec_hash[key] + end end end end