spec/unit/pretty_format_spec.rb in activeadmin-1.2.0 vs spec/unit/pretty_format_spec.rb in activeadmin-1.2.1

- old
+ new

@@ -6,21 +6,13 @@ def method_missing(*args, &block) mock_action_view.send *args, &block end - ['hello', 23, 5.67, 10**30, :foo].each do |obj| + ['hello', 23, 5.67, 10**30, :foo, Arbre::Element.new.br].each do |obj| it "should call `to_s` on #{obj.class}s" do expect(pretty_format(obj)).to eq obj.to_s end - end - - it "normalizes Arbre elements" do - expect(pretty_format(Arbre::Element.new.br)).to eq("<br>\n") - end - - it "sanitizes Arbre elements" do - expect(pretty_format(Arbre::Element.new.script('alert("foo");'))).to eq("alert(&amp;quot;foo&amp;quot;);\n") end shared_examples_for 'a time-ish object' do |t| it "formats it with the default long format" do expect(pretty_format(t)).to eq "February 28, 1985 20:15"