Sha256: e8ce6a0b0c230413adfb180992fbbb5cb83e83f654539a1e2d3e4c980a8dd609

Contents?: true

Size: 1.04 KB

Versions: 19

Compression:

Stored size: 1.04 KB

Contents

require File.dirname(__FILE__) + '/../test_helper'

class Muck::TopicsControllerTest < ActionController::TestCase

  tests Muck::TopicsController

  context "topics controller" do

    context "GET new" do
      setup do
        get :new
      end
      should_not_set_the_flash
      should_respond_with :success
      should_render_template :new
    end

    context "GET rss_discovery with term defined" do
      setup do
        get :rss_discovery, :id => 'ruby,rails'
      end
      should_not_set_the_flash
      should_respond_with :success
      should_render_template :rss_discovery
    end
    
    context "GET show with term defined" do
      setup do
        get :show, :id => 'ruby,rails'
      end
      should_not_set_the_flash
      should_respond_with :success
      should_render_template :show
    end
  
    context "GET show without terms" do
      setup do
        get :show, :id => ' '
      end
      should_set_the_flash_to(I18n.t('muck.raker.no_terms_error'))
      should_redirect_to("new topic") { new_topic_path }
    end
    
  end
  
end

Version data entries

19 entries across 19 versions & 1 rubygems

Version Path
muck-raker-0.2.11 test/rails_root/test/functional/topics_controller_test.rb
muck-raker-0.2.10 test/rails_root/test/functional/topics_controller_test.rb
muck-raker-0.2.9 test/rails_root/test/functional/topics_controller_test.rb
muck-raker-0.2.8 test/rails_root/test/functional/topics_controller_test.rb
muck-raker-0.2.7 test/rails_root/test/functional/topics_controller_test.rb
muck-raker-0.2.6 test/rails_root/test/functional/topics_controller_test.rb
muck-raker-0.2.5 test/rails_root/test/functional/topics_controller_test.rb
muck-raker-0.2.4 test/rails_root/test/functional/topics_controller_test.rb
muck-raker-0.2.3 test/rails_root/test/functional/topics_controller_test.rb
muck-raker-0.2.2 test/rails_root/test/functional/topics_controller_test.rb
muck-raker-0.2.0 test/rails_root/test/functional/topics_controller_test.rb
muck-raker-0.1.49 test/rails_root/test/functional/topics_controller_test.rb
muck-raker-0.1.48 test/rails_root/test/functional/topics_controller_test.rb
muck-raker-0.1.47 test/rails_root/test/functional/topics_controller_test.rb
muck-raker-0.1.46 test/rails_root/test/functional/topics_controller_test.rb
muck-raker-0.1.45 test/rails_root/test/functional/topics_controller_test.rb
muck-raker-0.1.43 test/rails_root/test/functional/topics_controller_test.rb
muck-raker-0.1.42 test/rails_root/test/functional/topics_controller_test.rb
muck-raker-0.1.41 test/rails_root/test/functional/topics_controller_test.rb