Skip to content

Instantly share code, notes, and snippets.

@alg
Created February 13, 2010 00:00
Show Gist options
  • Save alg/303124 to your computer and use it in GitHub Desktop.
Save alg/303124 to your computer and use it in GitHub Desktop.
require 'test_helper'
class StaticPagesControllerTest < ActionController::TestCase
%w( faq about privacy terms_and_conditions ).each do |page|
should_route :get, "/#{page}", :controller => :static_pages, :action => page.to_sym
context "Accessing #{page} page" do
setup { get page }
should_respond_with :success
should_render_template page
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment