MCPcopy Create free account
hub / github.com/apache/arrow / test_http_basic_auth_invalid_password

Function test_http_basic_auth_invalid_password

python/pyarrow/tests/test_flight.py:1594–1602  ·  view source on GitHub ↗

Test that auth fails with the wrong password.

()

Source from the content-addressed store, hash-verified

1592
1593
1594def test_http_basic_auth_invalid_password():
1595 """Test that auth fails with the wrong password."""
1596 with EchoStreamFlightServer(auth_handler=basic_auth_handler) as server, \
1597 FlightClient(('localhost', server.port)) as client:
1598 action = flight.Action("who-am-i", b"")
1599 with pytest.raises(flight.FlightUnauthenticatedError,
1600 match=".*wrong password.*"):
1601 client.authenticate(HttpBasicClientAuthHandler('test', 'wrong'))
1602 next(client.do_action(action))
1603
1604
1605def test_token_auth():

Callers

nothing calls this directly

Calls 5

FlightClientClass · 0.90
authenticateMethod · 0.45
do_actionMethod · 0.45

Tested by

no test coverage detected