Commit ed749ee3880fca80662eaea5551877d4c19abe24

Authored by Daniela Feitosa
1 parent 40cccd78

Replacing anything by real parameter on profile_design test

test/functional/profile_design_controller_test.rb
... ... @@ -412,14 +412,14 @@ class ProfileDesignControllerTest < Test::Unit::TestCase
412 412 end
413 413  
414 414 should 'allow admins to add RawHTMLBlock' do
415   - profile.stubs(:is_admin?).with(anything).returns(true)
  415 + profile.stubs(:is_admin?).with(profile.environment).returns(true)
416 416 @controller.stubs(:user).returns(profile)
417 417 get :add_block, :profile => 'designtestuser'
418 418 assert_tag :tag => 'input', :attributes => { :id => 'type_rawhtmlblock', :value => 'RawHTMLBlock' }
419 419 end
420 420  
421 421 should 'not allow normal users to add RawHTMLBlock' do
422   - profile.stubs(:is_admin?).with(anything).returns(false)
  422 + profile.stubs(:is_admin?).with(profile.environment).returns(false)
423 423 @controller.stubs(:user).returns(profile)
424 424 get :add_block, :profile => 'designtestuser'
425 425 assert_no_tag :tag => 'input', :attributes => { :id => 'type_rawhtmlblock', :value => 'RawHTMLBlock' }
... ...