Sha256: 402800e92581e843717d3b63d0d09e4211dcde7cc84e7554250824932c165667
Contents?: true
Size: 961 Bytes
Versions: 11
Compression:
Stored size: 961 Bytes
Contents
require "helper" describe Picasa::Template do it "has name" do template = Picasa::Template.new(:new_album, {}) assert_equal :new_album, template.name end it "has params" do template = Picasa::Template.new(:new_album, {:title => "My album"}) assert_equal({:title => "My album"}, template.params) end describe "new_album" do it "renders title" do template = Picasa::Template.new(:new_album, {:title => "My album"}) assert_match %q{<title type="text">My album</title>}, template.render end it "renders summary" do template = Picasa::Template.new(:new_album, {:summary => "My summary"}) assert_match %q{<summary type="text">My summary</summary>}, template.render end it "escapes special characters" do template = Picasa::Template.new(:new_album, {:summary => "Marge & Homer"}) assert_match %q{<summary type="text">Marge & Homer</summary>}, template.render end end end
Version data entries
11 entries across 11 versions & 1 rubygems