Sha256: 7f999cc2713a43dc7b475691c596b3b2b9f59fcc3f56d89c8451c270ec8e5dd3

Contents?: true

Size: 1.46 KB

Versions: 2

Compression:

Stored size: 1.46 KB

Contents

require 'helper'

class TopHatPluginTestCase < Test::Unit::TestCase
  
  context "loading the TopHat plugin" do
    
    setup do
      @template = ActionView::Base.new
    end
  
    should "be mixed into ActionView::Base" do
      assert ActionView::Base.included_modules.include?(TopHat::TitleHelper)
      assert ActionView::Base.included_modules.include?(TopHat::MetaHelper)
      assert ActionView::Base.included_modules.include?(TopHat::StylesheetHelper)
    end
  
    should "respond to 'title' helper" do
      assert @template.respond_to?(:title)
    end

    should "respond to 'title' helper alias" do
      assert @template.respond_to?(:t)
    end

    should "respond to 'description' helper" do
      assert @template.respond_to?(:description)
    end    

    should "respond to 'keywords' helper" do
      assert @template.respond_to?(:keywords)
    end

    should "respondo to 'ie_5_conditional' helper" do
      assert @template.respond_to?(:ie_5_conditional)
    end
    
    should "respondo to 'ie_5_5_conditional' helper" do
      assert @template.respond_to?(:ie_5_5_conditional)
    end
    
    should "respondo to 'ie_6_conditional' helper" do
      assert @template.respond_to?(:ie_6_conditional)
    end
    
    should "respond to 'ie_7_conditional' helper" do
      assert @template.respond_to?(:ie_7_conditional)
    end
    
    should "respond to 'ie_8_conditional' helper" do
      assert @template.respond_to?(:ie_8_conditional)
    end 
  
  end
  
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
tophat-1.2.0 test/test_tophat.rb
tophat-1.1.0 test/test_tophat.rb