Skip to content

Tests for CreateGitlabAccountRequestView (users)

MariaV requested to merge more_test into master

Changed a line in CreateGitlabAccountRequestView that caused users that had previously rejected requests to be redirected to success-view before new GitlabAccountRequest was created, which led to the object never being created in database.

Wrote 9 tests testing the functions of the CreateGitlabAccountRequestView, including for:

  • GET, user not logged in
  • POST, user not logged in,
  • GET, user logged in, but no UserIdentifier in database
  • POST, user logged in, but no UserIdentifier in database
  • GET, user logged in, user identifier in database
  • POST, user logged in, user identifier in database, no linked GL requests
  • POST, user logged in, user in database, linked GL request with rejected status
  • POST, user logged in, user in database, linked GL request already existing with PENDING status
  • POST, user attempts to post with bad identifier.

Ran coverage, all logic branches of CreateGitlabAccountRequestView are fully covered at this time.

Edited by MariaV

Merge request reports

Loading