You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using connexion (v3.1.0) in unit testing. I have an API endpoint that uses content that multipart/form-data content. In connexion v2 (v2.14.2) this was possible. In connexion v3 I appear to be unable to test these endpoints without encountering a MultiPartException('Missing boundary in multipart.') ERROR.
I should be able to use the test_client() to test APIs with multipart/form-data content. This might be a problem with connexion or starlette, it's certainly not something the test should need to be responsible for - after all the content tells the test client what's expected - I present data (in a Dictionary) - the test client adjusts it to satisfy the defined content for the API being tested.
Actual behaviour
I get an exception: -
ERROR connexion.middleware.exceptions:exceptions.py:108 MultiPartException('Missing boundary in multipart.')
Description
I'm using connexion (v3.1.0) in unit testing. I have an API endpoint that uses content that
multipart/form-data
content. In connexion v2 (v2.14.2) this was possible. In connexion v3 I appear to be unable to test these endpoints without encountering aMultiPartException('Missing boundary in multipart.')
ERROR.Expected behaviour
I should be able to use the
test_client()
to test APIs withmultipart/form-data
content. This might be a problem withconnexion
orstarlette
, it's certainly not something the test should need to be responsible for - after all the content tells the test client what's expected - I present data (in a Dictionary) - the test client adjusts it to satisfy the defined content for the API being tested.Actual behaviour
I get an exception: -
Steps to reproduce
See connexion discussion 1964.
Additional info:
Output of the commands:
python --version
(Python 3.12.4)pip show connexion | grep "^Version\:"
(Version: 3.1.0)The text was updated successfully, but these errors were encountered: