Sha256: c0da41b608d7ad05df565311598701cd97f55e8bd3953eebc72a4360693427d9

Contents?: true

Size: 743 Bytes

Versions: 11

Compression:

Stored size: 743 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
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
picasa-0.6.5 test/template_test.rb
picasa-0.6.4 test/template_test.rb
picasa-0.6.3 test/template_test.rb
picasa-0.6.2 test/template_test.rb
picasa-0.6.1 test/template_test.rb
picasa-0.6.0 test/template_test.rb
picasa-0.5.4 test/template_test.rb
picasa-0.5.3 test/template_test.rb
picasa-0.5.2 test/template_test.rb
picasa-0.5.1 test/template_test.rb
picasa-0.5.0 test/template_test.rb