Sha256: b8c85ed1d10580898320b0120aa8d4107a3bde990a9b991600c5b45aac575394

Contents?: true

Size: 1.24 KB

Versions: 61

Compression:

Stored size: 1.24 KB

Contents

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

class DescriptionGenerationSpecController < ActionController::Base
  def render_action
  end

  def redirect_action
    redirect_to :action => :render_action
  end
end

describe "Description generation", :type => :controller do
  controller_name :description_generation_spec
  
  after(:each) do
    Spec::Matchers.clear_generated_description
  end

  it "should generate description for render_template" do
    get 'render_action'
    response.should render_template("render_action")
    Spec::Matchers.generated_description.should == "should render template \"render_action\""
  end

  it "should generate description for render_template with full path" do
    get 'render_action'
    response.should render_template("description_generation_spec/render_action")
    Spec::Matchers.generated_description.should == "should render template \"description_generation_spec/render_action\""
  end

  it "should generate description for redirect_to" do
    get 'redirect_action'
    response.should redirect_to("http://test.host/description_generation_spec/render_action")
    Spec::Matchers.generated_description.should == "should redirect to \"http://test.host/description_generation_spec/render_action\""
  end

end

Version data entries

61 entries across 61 versions & 10 rubygems

Version Path
dchelimsky-rspec-rails-1.1.10 spec/rails/matchers/description_generation_spec.rb
dchelimsky-rspec-rails-1.1.11.1 spec/rails/matchers/description_generation_spec.rb
dchelimsky-rspec-rails-1.1.11.2 spec/rails/matchers/description_generation_spec.rb
dchelimsky-rspec-rails-1.1.11.3 spec/rails/matchers/description_generation_spec.rb
dchelimsky-rspec-rails-1.1.11 spec/rails/matchers/description_generation_spec.rb
dchelimsky-rspec-rails-1.1.6 spec/rails/matchers/description_generation_spec.rb
dchelimsky-rspec-rails-1.1.7 spec/rails/matchers/description_generation_spec.rb
dchelimsky-rspec-rails-1.1.8 spec/rails/matchers/description_generation_spec.rb
dchelimsky-rspec-rails-1.1.9 spec/rails/matchers/description_generation_spec.rb
jcnetdev-rspec-rails-1.1.5 spec/rails/matchers/description_generation_spec.rb
jnstq-acts_as_sms-0.1.0 test/vendor/plugins/rspec-rails/spec/rails/matchers/description_generation_spec.rb
jnstq-acts_as_sms-0.1.1 test/vendor/plugins/rspec-rails/spec/rails/matchers/description_generation_spec.rb
jnstq-acts_as_sms-0.1.3 test/vendor/plugins/rspec-rails/spec/rails/matchers/description_generation_spec.rb
jnstq-acts_as_sms-0.1.4 test/vendor/plugins/rspec-rails/spec/rails/matchers/description_generation_spec.rb
jstorimer-deep-test-2.0.0 sample_rails_project/vendor/plugins/rspec_on_rails/spec/rails/matchers/description_generation_spec.rb
jstorimer-deep-test-1.4.0 sample_rails_project/vendor/plugins/rspec_on_rails/spec/rails/matchers/description_generation_spec.rb
jstorimer-deep-test-1.3.0 sample_rails_project/vendor/plugins/rspec_on_rails/spec/rails/matchers/description_generation_spec.rb
jstorimer-deep-test-1.2.0 sample_rails_project/vendor/plugins/rspec_on_rails/spec/rails/matchers/description_generation_spec.rb
jstorimer-deep-test-1.1.0 sample_rails_project/vendor/plugins/rspec_on_rails/spec/rails/matchers/description_generation_spec.rb
jstorimer-deep-test-1.0.0 sample_rails_project/vendor/plugins/rspec_on_rails/spec/rails/matchers/description_generation_spec.rb