mirror of
https://github.com/mCaptcha/mCaptcha.git
synced 2026-02-12 10:35:39 +00:00
tests: get status code from err
This commit is contained in:
@@ -170,7 +170,6 @@ mod tests {
|
||||
ROUTES.account.update_password,
|
||||
&update_password,
|
||||
ServiceError::PasswordsDontMatch,
|
||||
StatusCode::BAD_REQUEST,
|
||||
)
|
||||
.await;
|
||||
|
||||
@@ -186,7 +185,6 @@ mod tests {
|
||||
ROUTES.account.update_password,
|
||||
&update_password,
|
||||
ServiceError::WrongPassword,
|
||||
StatusCode::UNAUTHORIZED,
|
||||
)
|
||||
.await;
|
||||
|
||||
|
||||
@@ -157,7 +157,6 @@ async fn email_udpate_password_validation_del_userworks() {
|
||||
ROUTES.account.update_email,
|
||||
&email_payload,
|
||||
ServiceError::EmailTaken,
|
||||
StatusCode::BAD_REQUEST,
|
||||
)
|
||||
.await;
|
||||
|
||||
@@ -171,7 +170,6 @@ async fn email_udpate_password_validation_del_userworks() {
|
||||
ROUTES.account.delete,
|
||||
&payload,
|
||||
ServiceError::WrongPassword,
|
||||
StatusCode::UNAUTHORIZED,
|
||||
)
|
||||
.await;
|
||||
|
||||
|
||||
@@ -340,7 +340,6 @@ mod tests {
|
||||
ROUTES.mcaptcha.delete,
|
||||
&delete_payload,
|
||||
ServiceError::WrongPassword,
|
||||
StatusCode::UNAUTHORIZED,
|
||||
)
|
||||
.await;
|
||||
|
||||
|
||||
@@ -71,7 +71,6 @@ async fn auth_works() {
|
||||
ROUTES.auth.register,
|
||||
&msg,
|
||||
ServiceError::UsernameTaken,
|
||||
StatusCode::BAD_REQUEST,
|
||||
)
|
||||
.await;
|
||||
|
||||
@@ -83,7 +82,6 @@ async fn auth_works() {
|
||||
ROUTES.auth.register,
|
||||
&msg,
|
||||
ServiceError::EmailTaken,
|
||||
StatusCode::BAD_REQUEST,
|
||||
)
|
||||
.await;
|
||||
|
||||
@@ -98,7 +96,6 @@ async fn auth_works() {
|
||||
ROUTES.auth.login,
|
||||
&creds,
|
||||
ServiceError::AccountNotFound,
|
||||
StatusCode::NOT_FOUND,
|
||||
)
|
||||
.await;
|
||||
|
||||
@@ -109,7 +106,6 @@ async fn auth_works() {
|
||||
ROUTES.auth.login,
|
||||
&creds,
|
||||
ServiceError::AccountNotFound,
|
||||
StatusCode::NOT_FOUND,
|
||||
)
|
||||
.await;
|
||||
|
||||
@@ -123,7 +119,6 @@ async fn auth_works() {
|
||||
ROUTES.auth.login,
|
||||
&creds,
|
||||
ServiceError::WrongPassword,
|
||||
StatusCode::UNAUTHORIZED,
|
||||
)
|
||||
.await;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user