Account Tests¶
-
class
account.tests.AWSCredViewTest(methodName='runTest')¶ Class for testing AWS Credential View.
-
setUp()¶ Create basic test users
-
test_existing_cred_request()¶ Test that accessing the AWS Cred Request View with an existing request switches its state to pending and redirects to profile.
-
test_no_cred_request()¶ Test that accessing the AWS Cred Request View without an existing request creates one and redirects to profile.
-
-
class
account.tests.ChangePWDTest(methodName='runTest')¶ Class for testing the user profile page.
-
setUp()¶ Create basic test user and associate it with a basic test IAM and group.
-
test_incorrect_pwd_change_with_post_request()¶ Test that updating the password with unmatched passwords of a logged in user fails.
-
test_pwd_change_with_post_request()¶ Test that updating the password of a logged in user is successful.
-
test_unmatched_pwd_change_with_post_request()¶ Test that updating the password with unmatched passwords of a logged in user fails.
-
-
class
account.tests.IAMCreateTest(methodName='runTest')¶ Class for testing IAM creation from a JSON file.
-
setUp()¶ none
-
test_duplicate_iam_name()¶ Test that creating an IAM with a duplicate username fails.
-
test_empty_json()¶ Test that creating an IAM with an empty json file fails.
-
test_exception()¶ Test that creating an IAM with an exception fails (in the test a file with improper json data is used).
-
test_existing_group()¶ Test that creating an IAM with entirely unique data (except that it should be attatched to an existing group) works.
-
test_existing_user()¶ Test that creating an IAM with entirely unique data (except that it should be attatched to an existing user) works.
-
test_unique_data()¶ Test that creating an IAM with entirely unique data works.
-
-
class
account.tests.ProfileViewTest(methodName='runTest')¶ Class for testing the user profile page.
-
setUp()¶ Create basic test user and associate it with a basic test IAM and group.
-
test_profile_view_with_get_request()¶ Test that checking the profile view of a logged in user displays the user’s email, name, and IAM username.
-
test_profile_view_with_post_request()¶ Test that updating the profile view of a logged in user is successful.
-
-
class
account.tests.UserLoginViewTest(methodName='runTest')¶ Class for testing user login.
-
setUp()¶ Create basic test user and associate it with a basic test IAM and group.
-
test_failed_login_view_with_iam()¶ Test that logging in with incorrect credentials doesnt logins in and redirects to this login page.
-
test_login_view_with_iam()¶ Test that logging in with email logins in and redirects to profile page successfully.
-
test_login_view_with_iam_non_migrated()¶ Test that logging in with email logins in and redirects to change password page successfully if the user has not yet made a password.
-
test_redirect_if_logged_in_already()¶ Test that viewing login page when already logged in redirects to profile page.
-
test_redirect_if_logged_in_already_next()¶ Test that viewing login page when already logged in redirects to profile page.
-
test_redirect_if_logged_out_next()¶ Test that viewing login page when already logged in redirects to profile page.
-
-
class
account.tests.UserSignUpViewTest(methodName='runTest')¶ Class for testing user signup.
-
setUp()¶ none
-
test_sign_up_view_with_post_request()¶ Test that signing up with email signs up and redirects to home page successfully.
-
test_unmatched_sign_up_view_with_post_request()¶ Test that signing up with unmatching passwords redirects to signup page successfully.
-
-
class
account.tests.UserTestCase(methodName='runTest')¶ Class for testing user information.
-
setUp()¶ Create basic test users.
-
test_admin_perm()¶ Test that an admin user has the proper permissions
-
test_get_empty_name_with_user()¶ Test that user’s full name is returned accurately
-
test_get_full_name_with_user()¶ Test that user’s full name is returned accurately
-
test_get_short_name_with_user()¶ Test that user’s email is returned accurately
-
test_get_strs()¶ Test that user’s email and group and iam names are returned accurately (when calling __str__())
-
-
account.tests¶ alias of
account.tests