You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
416 B
20 lines
416 B
12 years ago
|
require 'spec_helper'
|
||
|
|
||
|
describe Users::HostsController do
|
||
|
include_context "data"
|
||
|
|
||
|
before do
|
||
|
sign_in user
|
||
|
@controller.stub(:nested_parent_record => host_domain)
|
||
|
end
|
||
|
|
||
|
it "#new_model is wired" do
|
||
|
@controller.send(:new_model).user.should == user
|
||
|
end
|
||
|
|
||
|
it "#before_create_save wires" do
|
||
|
@controller.send(:before_create_save, host_a_record)
|
||
|
host_a_record.user.should == user
|
||
|
end
|
||
|
end
|