Sha256: 7a24ef64d10f4f725b60195a07c917c7fae4a1bda04f36a4cecc800e259bced3

Contents?: true

Size: 561 Bytes

Versions: 24

Compression:

Stored size: 561 Bytes

Contents

require File.expand_path('../test_helper', File.dirname(__FILE__))

class SitemapTest < ActiveSupport::TestCase
  class DummySitemapExtension
    @@calls = 0
    def self.calls
      @@calls
    end
    def self.callback(cms_site, view, xml)
      @@calls = @@calls + 1
    end
  end

  def test_should_get_registered_extensions
    ComfortableMexicanSofa::Sitemap.register_extension(DummySitemapExtension.method(:callback))
    ComfortableMexicanSofa::Sitemap.process(cms_sites(:default), nil, "xml")
    assert_equal 1, DummySitemapExtension.calls
  end

end

Version data entries

24 entries across 24 versions & 1 rubygems

Version Path
comfortable_mexican_sofa-1.6.31 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.8.3 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.8.2 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.8.1 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.8.0 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.6.30 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.7.3 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.7.1 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.7.0 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.6.26 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.6.25 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.6.24 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.6.23 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.6.22 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.6.21 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.6.20 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.6.19 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.6.18 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.6.17 test/unit/sitemap_test.rb
comfortable_mexican_sofa-1.6.16 test/unit/sitemap_test.rb