Commit 22b5ba967193da198fc53415f2898833487fd410
1 parent
c2d5c7df
Exists in
master
and in
29 other branches
Fixing some functional tests
- textile doesn't needs to be sanitized
Showing
2 changed files
with
3 additions
and
16 deletions
Show diff stats
app/controllers/my_profile/profile_members_controller.rb
... | ... | @@ -25,9 +25,11 @@ class ProfileMembersController < MyProfileController |
25 | 25 | session[:notice] = _('Couldn\'t change the roles') |
26 | 26 | redirect_to :action => 'index' |
27 | 27 | end |
28 | + else | |
29 | + redirect_to :action => 'index' | |
28 | 30 | end |
29 | 31 | end |
30 | - | |
32 | + | |
31 | 33 | def last_admin |
32 | 34 | @roles = [Profile::Roles.admin(environment.id)] |
33 | 35 | @pre_population = [].to_json | ... | ... |
test/functional/cms_controller_test.rb
... | ... | @@ -433,21 +433,6 @@ class CmsControllerTest < Test::Unit::TestCase |
433 | 433 | assert_equal [c1, c3], saved.categories |
434 | 434 | end |
435 | 435 | |
436 | - should 'filter html from textile article name' do | |
437 | - post :new, :type => 'TextileArticle', :profile => profile.identifier, :article => { :name => 'a <strong>test</strong> article', :body => 'the text of the article ...' } | |
438 | - assert_sanitized assigns(:article).name | |
439 | - end | |
440 | - | |
441 | - should 'filter html from textile article abstract' do | |
442 | - post :new, :type => 'TextileArticle', :profile => profile.identifier, :article => { :name => 'article', :abstract => '<strong>abstract</strong>', :body => 'the text of the article ...' } | |
443 | - assert_sanitized assigns(:article).abstract | |
444 | - end | |
445 | - | |
446 | - should 'filter html from textile article body' do | |
447 | - post :new, :type => 'TextileArticle', :profile => profile.identifier, :article => { :name => 'article', :abstract => 'abstract', :body => 'the <b>text</b> of <a href=#>the</a> article ...' } | |
448 | - assert_sanitized assigns(:article).body | |
449 | - end | |
450 | - | |
451 | 436 | should 'filter html with white_list from tiny mce article name' do |
452 | 437 | post :new, :type => 'TinyMceArticle', :profile => profile.identifier, :article => { :name => "<strong>test</strong>", :body => 'the text of the article ...' } |
453 | 438 | assert_equal "<strong>test</strong>", assigns(:article).name | ... | ... |