Skip to content

Commit

Permalink
Merge pull request #77 from ClogenyTechnologies/pd-OC-10611-custom-ar…
Browse files Browse the repository at this point in the history
…guments

Unit test for custom_arguments passed.
  • Loading branch information
Mukta Aphale committed Apr 28, 2014
2 parents ef518c2 + b2ebbb6 commit 6f43d29
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions spec/unit/openstack_server_create_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,17 @@
it_behaves_like Chef::Knife::Cloud::ServerCreateCommand, Chef::Knife::Cloud::OpenstackServerCreate.new

describe "#create_service_instance" do
before(:each) do
@instance = Chef::Knife::Cloud::OpenstackServerCreate.new
end

it "return OpenstackService instance" do
instance = Chef::Knife::Cloud::OpenstackServerCreate.new
expect(instance.create_service_instance).to be_an_instance_of(Chef::Knife::Cloud::OpenstackService)
expect(@instance.create_service_instance).to be_an_instance_of(Chef::Knife::Cloud::OpenstackService)
end

it "has custom_arguments as its option" do
expect(@instance.options.include? :custom_attributes).to be true
end
end

describe "#validate_params!" do
Expand Down

0 comments on commit 6f43d29

Please sign in to comment.