Merge remote-tracking branch 'upstream/pull/3409'
This commit is contained in:
commit
dcaf21602c
2 changed files with 16 additions and 1 deletions
|
@ -23,7 +23,7 @@ class Ability
|
|||
can [:index, :show], Redaction
|
||||
can [:new, :create, :destroy], :session
|
||||
can [:index, :show, :data, :georss, :picture, :icon], Trace
|
||||
can [:terms, :new, :create, :save, :show, :auth_success, :auth_failure], User
|
||||
can [:terms, :new, :create, :save, :suspended, :show, :auth_success, :auth_failure], User
|
||||
can [:index, :show, :blocks_on, :blocks_by], UserBlock
|
||||
can [:index, :show], Node
|
||||
can [:index, :show, :full, :ways_for_node], Way
|
||||
|
|
15
test/system/user_suspension_test.rb
Normal file
15
test/system/user_suspension_test.rb
Normal file
|
@ -0,0 +1,15 @@
|
|||
require "application_system_test_case"
|
||||
|
||||
class UserSuspensionTest < ApplicationSystemTestCase
|
||||
test "User shown a message when suspended mid-session" do
|
||||
user = create(:user)
|
||||
sign_in_as(user)
|
||||
visit edit_account_path
|
||||
assert_content "My Settings"
|
||||
|
||||
user.update(:status => "suspended")
|
||||
|
||||
visit edit_account_path
|
||||
assert_content "This decision will be reviewed by an administrator shortly"
|
||||
end
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue