Sha256: fa6f044845099407c0fb455cd74dc1ca7332f4928e1d474016638541b8c227c7
Contents?: true
Size: 1.37 KB
Versions: 4
Compression:
Stored size: 1.37 KB
Contents
# Copyright (c) 2008-2013 Michael Dvorkin and contributors. # # Fat Free CRM is freely distributable under the terms of MIT license. # See MIT-LICENSE file or http://www.opensource.org/licenses/mit-license.php #------------------------------------------------------------------------------ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') describe "/contacts/destroy" do include ContactsHelper before do login_and_assign assign(:contact, @contact = FactoryGirl.create(:contact)) assign(:contacts, [ @contact ].paginate) end it "should blind up destroyed contact partial" do render rendered.should include(%Q/$("contact_#{@contact.id}").visualEffect("blind_up"/) end it "should update contacts sidebar when called from contacts index" do controller.request.env["HTTP_REFERER"] = "http://localhost/contacts" render rendered.should have_rjs("sidebar") do |rjs| with_tag("div[id=recently]") end end it "should update pagination when called from contacts index" do controller.request.env["HTTP_REFERER"] = "http://localhost/contacts" render rendered.should have_rjs("paginate") end it "should update recently viewed items when called from related asset" do controller.request.env["HTTP_REFERER"] = "http://localhost/accounts/123" render rendered.should have_rjs("recently") end end
Version data entries
4 entries across 4 versions & 1 rubygems