Skip to content

Fix matching request data when files are provided#252

Merged
lundberg merged 4 commits intomasterfrom
fix/form-data-with-files
Mar 18, 2024
Merged

Fix matching request data when files are provided#252
lundberg merged 4 commits intomasterfrom
fix/form-data-with-files

Conversation

@lundberg
Copy link
Copy Markdown
Owner

When posting data with httpx along with files, the request body gets encoded as multipart form-data. This PR adds support for matching request data even if files are included in the actual request.

As a bonus feature, the data pattern gets support for the contains lookup. The eq lookup is kept as default for now, but will probably be changed to contains in the future.

Fixes #251

@codecov
Copy link
Copy Markdown

codecov bot commented Mar 15, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (58ad17e) to head (78d8e8a).

Additional details and impacted files
@@            Coverage Diff            @@
##            master      #252   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           20        21    +1     
  Lines         2759      2807   +48     
  Branches       418       423    +5     
=========================================
+ Hits          2759      2807   +48     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@lundberg lundberg merged commit 4bc9c5d into master Mar 18, 2024
@lundberg lundberg deleted the fix/form-data-with-files branch March 18, 2024 16:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support multipart encoding in Data pattern

1 participant