Skip to content

Commit

Permalink
Call tag_details with the :no_cache option. Updated spec to test for it.
Browse files Browse the repository at this point in the history
  • Loading branch information
lgalis committed May 31, 2018
1 parent fbd89d2 commit 3b6f0bb
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion app/views/layouts/exp_atom/_edit_tags.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
exp_model Model in use for this expression
- opts = ["<#{_('Choose')}>"]
- opts += MiqExpression.tag_details(nil, {})
- opts += MiqExpression.tag_details(nil, {:no_cache => true})

.spacer

Expand Down
4 changes: 2 additions & 2 deletions spec/controllers/ops_controller/ops_rbac_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,7 @@
expect(@edit[:filter_expression][:exp_typ]).to eq('tags')
end

it "calls MiqExpression.tag_details to get only the My Company type tag categories" do
it "calls MiqExpression.tag_details with :no_cache to get only the My Company type tag categories" do
new = {:use_filter_expression => true,
:name => 'Name',
:description => "Test",
Expand Down Expand Up @@ -408,7 +408,7 @@
allow(controller).to receive(:replace_right_cell)

post :tree_select, :params => { :id => 'root', :format => :js }
expect(MiqExpression).to receive(:tag_details)
expect(MiqExpression).to receive(:tag_details).with(nil, :no_cache => true)
post :rbac_group_field_changed, :params => { :id => 'new', :use_filter_expression => "true"}
end

Expand Down

0 comments on commit 3b6f0bb

Please sign in to comment.