Skip to content

Commit

Permalink
service_catalog to service_dialog
Browse files Browse the repository at this point in the history
update specs to reflect changes
  • Loading branch information
Jillian Tullo committed Aug 31, 2016
1 parent 5a24e6f commit 3eb2f6b
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
2 changes: 1 addition & 1 deletion app/controllers/api/base_controller/blueprints.rb
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def service_catalog_options(bundle)
end

def service_dialog_options(bundle)
Dialog.find(parse_id(bundle["service_dialog"], :service_dialogs)) if bundle["service_catalog"]
Dialog.find(parse_id(bundle["service_dialog"], :service_dialogs)) if bundle["service_dialog"]
end
end
end
Expand Down
9 changes: 8 additions & 1 deletion spec/requests/api/blueprints_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -319,6 +319,7 @@
blueprint = FactoryGirl.create(:blueprint)
original_service_template = FactoryGirl.create(:service_template)
original_service_catalog = FactoryGirl.create(:service_template_catalog)
service_dialog = FactoryGirl.create(:dialog_with_tab_and_group_and_field)
blueprint.create_bundle(:service_templates => [original_service_template],
:service_catalog => original_service_catalog)
api_basic_authorize action_identifier(:blueprints, :edit)
Expand All @@ -328,6 +329,9 @@
:action => "edit",
:resource => {
:bundle => {
:service_dialog => {
:id => service_dialog.id
},
:service_catalog => nil
}
}
Expand All @@ -351,7 +355,10 @@
:action => "edit",
:resource => {
:bundle => {
:service_dialog => nil
:service_catalog => {
:id => original_service_catalog.id
},
:service_dialog => nil
}
}
)
Expand Down

0 comments on commit 3eb2f6b

Please sign in to comment.