spec/lib/locomotive/render_spec.rb in locomotive_cms-0.0.1.4 vs spec/lib/locomotive/render_spec.rb in locomotive_cms-0.0.2

- old
+ new

@@ -59,21 +59,21 @@ context 'non published page' do before(:each) do @page.published = false - @controller.current_account = nil + @controller.current_admin = nil end it 'should return the 404 page if the page has not been published yet' do @controller.request.fullpath = '/contact' @controller.current_site.pages.expects(:where).with({ :fullpath => 'contact' }).returns([@page]) @controller.current_site.pages.expects(:not_found).returns([true]) @controller.send(:locomotive_page).should be_true end it 'should not return the 404 page if the page has not been published yet and admin is logged in' do - @controller.current_account = true + @controller.current_admin = true @controller.request.fullpath = '/contact' @controller.current_site.pages.expects(:where).with({ :fullpath => 'contact' }).returns([@page]) @controller.send(:locomotive_page).should == @page end \ No newline at end of file