diff --git a/spec/acts_as_taggable_on/tag_list_spec.rb b/spec/acts_as_taggable_on/tag_list_spec.rb index a642607c7..850095b94 100644 --- a/spec/acts_as_taggable_on/tag_list_spec.rb +++ b/spec/acts_as_taggable_on/tag_list_spec.rb @@ -62,6 +62,10 @@ @tag_list.to_s.should == "awesome, radical, cool, \"rad,bodacious\"" end + it "#from should return empty array if empty array is passed" do + ActsAsTaggableOn::TagList.from([]).should == [] + end + it "should be able to call to_s on a frozen tag list" do @tag_list.freeze lambda { @tag_list.add("cool","rad,bodacious") }.should raise_error diff --git a/spec/acts_as_taggable_on/taggable_spec.rb b/spec/acts_as_taggable_on/taggable_spec.rb index 346e2f048..8132d190f 100644 --- a/spec/acts_as_taggable_on/taggable_spec.rb +++ b/spec/acts_as_taggable_on/taggable_spec.rb @@ -264,7 +264,8 @@ it "should return an empty scope for empty tags" do TaggableModel.tagged_with('').should == [] TaggableModel.tagged_with(' ').should == [] - TaggableModel.tagged_with(nil).should == [] + TaggableModel.tagged_with(nil).should == [] + TaggableModel.tagged_with([]).should == [] end it "should not create duplicate taggings" do