Mukezh commented on code in PR #4276:
URL: https://github.com/apache/iggy/pull/4276#discussion_r4174004356


##########
foreign/python/tests/test_user.py:
##########
@@ -30,12 +34,53 @@
     MAX_USERNAME_BYTES,
     MIN_PASSWORD_BYTES,
     MIN_USERNAME_BYTES,
+    get_http_server_config,
     get_server_config,
     unique_credentials,
     wait_for_ping,
     wait_for_server,
 )
 
+# IggyExpiry::NeverExpire serializes as u64::MAX.
+NEVER_EXPIRE = 18446744073709551615
+
+
[email protected]
+def personal_access_token(unique_name):
+    """Mint a PAT via HTTP so login tests do not need the Python create API."""
+    name = unique_name(min_bytes=16, max_bytes=30)

Review Comment:
   Done. removed the one-use fixture and moved the successful PAT test’s setup 
and cleanup directly into the test.



##########
foreign/python/tests/test_http_config.py:
##########
@@ -232,6 +232,26 @@ async def test_client_connects_and_pings(self):
         await client.connect()
         await wait_for_ping(client)
 
+    @pytest.mark.asyncio
+    async def test_login_user_returns_http_access_token(self):
+        """Test HTTP login returns user_id and a session TokenInfo."""

Review Comment:
   addressed.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to