From: Jan Provaznik <[email protected]>
---
src/spec/controllers/templates_controller_spec.rb | 7 +++----
1 files changed, 3 insertions(+), 4 deletions(-)
diff --git a/src/spec/controllers/templates_controller_spec.rb
b/src/spec/controllers/templates_controller_spec.rb
index bdd4290..6e23609 100644
--- a/src/spec/controllers/templates_controller_spec.rb
+++ b/src/spec/controllers/templates_controller_spec.rb
@@ -33,19 +33,18 @@ describe TemplatesController do
hydra = Typhoeus::Hydra.hydra
hydra.stub(:put, %r{http://localhost:9090/templates/.*}).and_return(
Typhoeus::Response.new(:code => 200))
+ Factory.create(:mock_cloud_account)
end
it "should create a new Image" do
- mock = Factory.create(:mock_provider)
lambda do
- post :build, :image => {:template_id => @template.id}, :targets =>
["mock"]
+ post :build, :template_id => @template.id, :targets => ["mock"]
end.should change(Image, :count).by(1)
end
it "should create a new ReplicatedImage" do
- mock = Factory.create(:mock_provider)
lambda do
- post :build, :image => {:template_id => @template.id}, :targets =>
["mock"]
+ post :build, :template_id => @template.id, :targets => ["mock"]
end.should change(ReplicatedImage, :count).by(1)
end
end
--
1.7.2.3
_______________________________________________
deltacloud-devel mailing list
[email protected]
https://fedorahosted.org/mailman/listinfo/deltacloud-devel