@@ -35,7 +35,7 @@ def test_demo_auth_signup(self):
3535 """Test that demo_auth handles signup correctly."""
3636 from main import demo_auth
3737
38- self .mock_auth .signup .return_value = {"_id" : "user_123" , "email" : "test@example.com" }
38+ self .mock_auth .sign_up .return_value = {"_id" : "user_123" , "email" : "test@example.com" }
3939 self .mock_auth .login .return_value = {"token" : "test_token_abc123" }
4040 self .mock_auth .get_token .return_value = "test_token_abc123"
4141 self .mock_auth .me .return_value = {
@@ -47,30 +47,30 @@ def test_demo_auth_signup(self):
4747 result = demo_auth (self .mock_client )
4848 assert result is not None
4949 assert result ["email" ] == "test@example.com"
50- self .mock_auth .signup .assert_called_once ()
50+ self .mock_auth .sign_up .assert_called_once ()
5151 self .mock_auth .login .assert_called_once ()
5252 self .mock_auth .me .assert_called_once ()
5353
5454 def test_demo_auth_login_fallback (self ):
5555 """Test that demo_auth falls back to login if signup fails."""
5656 from main import demo_auth
5757
58- self .mock_auth .signup .side_effect = Exception ("User already exists" )
58+ self .mock_auth .sign_up .side_effect = Exception ("User already exists" )
5959 self .mock_auth .login .return_value = {"token" : "test_token_abc123" }
6060 self .mock_auth .get_token .return_value = "test_token_abc123"
6161 self .mock_auth .me .return_value = {"_id" : "user_123" , "email" : "test@example.com" }
6262
6363 result = demo_auth (self .mock_client )
6464 assert result is not None
6565 assert result ["email" ] == "test@example.com"
66- self .mock_auth .signup .assert_called_once ()
66+ self .mock_auth .sign_up .assert_called_once ()
6767 self .mock_auth .login .assert_called_once ()
6868
6969 def test_demo_auth_login_failure (self ):
7070 """Test that demo_auth returns None on login failure."""
7171 from main import demo_auth
7272
73- self .mock_auth .signup .side_effect = Exception ("User exists" )
73+ self .mock_auth .sign_up .side_effect = Exception ("User exists" )
7474 self .mock_auth .login .side_effect = Exception ("Invalid credentials" )
7575
7676 result = demo_auth (self .mock_client )
@@ -116,5 +116,4 @@ def test_demo_mail(self):
116116
117117 # Should not raise any exceptions
118118 demo_mail (self .mock_client )
119- self .mock_mail .send .assert_called_once ()
120- < / arg_value > < / tool_call >
119+ self .mock_mail .send .assert_called_once ()
0 commit comments