Sha256: fe464bbd83e262fec89d342118ae4ba83cad55e92fc24bef752318b46a140af5

Contents?: true

Size: 527 Bytes

Versions: 6

Compression:

Stored size: 527 Bytes

Contents

require_relative "../../../test_helper"

class ContentTagsDateTest < ActiveSupport::TestCase

  setup do
    @page = comfy_cms_pages(:default)
  end

  def test_init
    tag = ComfortableMexicanSofa::Content::Tag::Date.new(@page, "test")
    assert_equal "test", tag.identifier
  end

  def test_content
    frag = comfy_cms_fragments(:datetime)
    tag = ComfortableMexicanSofa::Content::Tag::Date.new(@page, frag.identifier)
    assert_equal frag,          tag.fragment
    assert_equal frag.datetime, tag.content
  end

end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
comfortable_mexican_sofa-2.0.8 test/lib/content/tags/date_test.rb
comfortable_mexican_sofa-2.0.7 test/lib/content/tags/date_test.rb
comfortable_mexican_sofa-2.0.6 test/lib/content/tags/date_test.rb
comfortable_mexican_sofa-2.0.5 test/lib/content/tags/date_test.rb
comfortable_mexican_sofa-2.0.4 test/lib/content/tags/date_test.rb
comfortable_mexican_sofa-2.0.3 test/lib/content/tags/date_test.rb