forked from publiclab/plots2
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Shipcy banned users (publiclab#7181)
* Update admin_controller.rb * modified useremail function to include banned users * Update modified useremail function to include banned users * Update modified useremail function to include banned users * Update modified useremail function to include banned users * Update modified useremail function to include banned users * Update app/controllers/modified useremail function to include banned users Co-Authored-By: Sparks <[email protected]> * Update modified useremail function to include banned users * rename admin_controller.rb back * Update admin_controller_test.rb * Update codecov.yml Co-authored-by: Shipra Choudhary <[email protected]> Co-authored-by: Sparks <[email protected]> Co-authored-by: Jeffrey Warren <[email protected]>
- Loading branch information
1 parent
08ab5c0
commit 6ae4850
Showing
3 changed files
with
38 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -662,4 +662,21 @@ def teardown | |
assert_response :success | ||
assert_not_nil assigns(:comments) | ||
end | ||
|
||
test 'admin user should be able to view page to search users by email' do | ||
UserSession.create(users(:admin)) | ||
|
||
get :useremail | ||
|
||
assert_response :success | ||
end | ||
|
||
test 'admin user should be able to search users by email' do | ||
UserSession.create(users(:admin)) | ||
|
||
get :useremail, params: { address: '[email protected]', include_banned: 'true' } | ||
|
||
assert_response :success | ||
assert_not_nil assigns(:users) | ||
end | ||
end |