Sha256: a9a8fd537cca2b39ac551bb292cc977f866e2f00cebcb4cf00d56791cfaad8e7
Contents?: true
Size: 1.04 KB
Versions: 2
Compression:
Stored size: 1.04 KB
Contents
require File.dirname(__FILE__) + '/../spec_helper' describe SiteController do dataset :sites_site_users_and_site_pages, :site_home_pages before(:each) do logout VhostExtension.HOST = sites(:site_a).hostnames.first.domain # Pretend we're connected to site_a so the SiteScope works right rescue_action_in_public! # ActionController::TestCase no longer considers this request a local request # don't bork results with stale cache items Radiant::Cache.clear end it "should find and render the home page for the #{VhostExtension.HOST} site" do get :show_page, :url => '' response.should be_success response.body.should == 'Hello A' end it "should find and render a child page for the #{VhostExtension.HOST} site" do get :show_page, :url => 'page-a/' response.should be_success response.body.should == 'PageA Body' end it "should NOT find and render a child page for a site other than the #{VhostExtension.HOST} site" do get :show_page, :url => 'page-b/' response.should be_missing end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
radiant-vhost-extension-2.3.1 | spec/controllers/site_controller_spec.rb |
radiant-vhost-extension-2.3.0 | spec/controllers/site_controller_spec.rb |