File tree Expand file tree Collapse file tree 3 files changed +7
-4
lines changed
backend/app/modules/access Expand file tree Collapse file tree 3 files changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -57,11 +57,11 @@ def signup(body: UserCreate,
5757 try :
5858 user = create_user (db , body )
5959 except Exception as e :
60- raise HTTPException (status_code = 400 , detail = "Failed to create user" )
60+ raise HTTPException (status_code = 400 , detail = "Failed to create user in database " )
6161
6262 if user is None :
6363 raise HTTPException (status_code = 400 , detail = "User already exists" )
64-
64+
6565 # Add user to cognito
6666 try :
6767 cognito_client .sign_up (
@@ -73,9 +73,9 @@ def signup(body: UserCreate,
7373 )
7474 except Exception as e :
7575 print (e )
76- logging .error (f"Failed to create user: { e } " )
76+ logging .error (f"Failed to create user in cognito : { e } " )
7777 delete_user (db , user .id )
78- raise HTTPException (status_code = 400 , detail = "Failed to create user" )
78+ raise HTTPException (status_code = 400 , detail = "Failed to create user in cognito " )
7979
8080 # Add user to group
8181 try :
Original file line number Diff line number Diff line change @@ -93,6 +93,8 @@ describe('Sign Up', () => {
9393 . click ( ) ;
9494
9595 cy . wait ( '@signUp' ) . its ( 'request.body' ) . should ( 'deep.equal' , user ) ;
96+ // print the response body
97+ cy . wait ( '@signUp' ) . its ( 'response.body' ) . then ( console . log ) ;
9698
9799 cy . url ( ) . should ( 'include' , `signup/success?email=${ user . email } ` ) ;
98100 } ) ;
Original file line number Diff line number Diff line change @@ -3,6 +3,7 @@ import {api} from './api';
33export interface UserRole {
44 type : 'guest' | 'host' | 'coordinator' | 'admin' ;
55}
6+
67export interface User {
78 email : string ;
89 firstName : string ;
You can’t perform that action at this time.
0 commit comments