pundit: convert ip addresses to pundit.
This commit is contained in:
@@ -34,6 +34,11 @@ class IpAddressesControllerTest < ActionDispatch::IntegrationTest
|
||||
get_auth ip_addresses_path(search: { user_id: @user.id, group_by: "ip_addr" }), @mod
|
||||
assert_response :success
|
||||
end
|
||||
|
||||
should "not allow non-moderators to view IP addresses" do
|
||||
get_auth ip_addresses_path, @user
|
||||
assert_response 403
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user