File tree Expand file tree Collapse file tree 2 files changed +23
-0
lines changed
app/controllers/application_controller Expand file tree Collapse file tree 2 files changed +23
-0
lines changed Original file line number Diff line number Diff line change @@ -84,6 +84,8 @@ def x_button
84
84
85
85
# Process model actions that are currently implemented
86
86
if X_BUTTON_ALLOWED_ACTIONS [ action ] == :s1
87
+ # resetting action that was stored during other operations
88
+ @sb [ :action ] = nil if @sb
87
89
send ( method )
88
90
elsif X_BUTTON_ALLOWED_ACTIONS [ action ] == :s2
89
91
# don't need to set params[:id] and do find_checked_items for methods
Original file line number Diff line number Diff line change 110
110
expect ( response ) . to render_template ( :partial => 'vm_common/_resize' )
111
111
end
112
112
113
+ it 'can open instance refresh tab' do
114
+ post :explorer
115
+ expect ( response . status ) . to eq ( 200 )
116
+ allow ( controller ) . to receive ( :x_node ) . and_return ( "v-#{ vm_openstack . id } " )
117
+
118
+ post :x_button , :params => { :pressed => 'instance_refresh' , :id => vm_openstack . id }
119
+ expect ( response . status ) . to eq ( 200 )
120
+ end
121
+
122
+ it 'can do instance refresh after its reconfigure' do
123
+ post :explorer
124
+ expect ( response . status ) . to eq ( 200 )
125
+ allow ( controller ) . to receive ( :x_node ) . and_return ( "v-#{ vm_openstack . id } " )
126
+
127
+ post :x_button , :params => { :pressed => 'instance_resize' , :id => vm_openstack . id }
128
+ expect ( response . status ) . to eq ( 200 )
129
+
130
+ post :x_button , :params => { :pressed => 'instance_refresh' , :id => vm_openstack . id }
131
+ expect ( response . status ) . to eq ( 200 )
132
+ end
133
+
113
134
it 'can open instance live migrate tab' do
114
135
post :explorer
115
136
expect ( response . status ) . to eq ( 200 )
You can’t perform that action at this time.
0 commit comments