Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added support for defining http requests in a .http file #1619

Open
wants to merge 19 commits into
base: master
Choose a base branch
from

Conversation

AlessandroColi
Copy link

As asked by issue #758 we added basic support for defining requests in a .HTTP file by using the --http-file flag followed by the file name instead of the URL

eliasfloreteng and others added 19 commits February 25, 2025 17:53
split the .http file into blocks
gets method and URL from requests
cleans comments
fix API's
#6), to search for dependencies (#9), to extract the name of a request (#10), to replace the global values (#4). Also added some attributes to the Request class (#7)
also brings other function in the logic
* Handle and skip empty request segments

Co-authored-by: Jakub Rybak <[email protected]>

* Fix splitting of requests

Co-authored-by: Jakub Rybak <[email protected]>

* Parse and pass request body

Co-authored-by: Jakub Rybak <[email protected]>

* Format files

Co-authored-by: Jakub Rybak <[email protected]>

* Format definition.py to follow code style

Co-authored-by: Jakub Rybak <[email protected]>

---------

Co-authored-by: Jakub Rybak <[email protected]>
* [feat] added unit tests for split_requests (#12)

* [fix] fixed the structure of split_requests function (#12)

* [fix] modified get_dependencies to return only unique dependencies (#9, #12)

* [feat] added unit tests for get_dependencies (#12)

* [feat][fix] fixed 2 cases with non-deterministic results and added test_log (REQ_007) (#12)

* [fix] fixed possible errors and simplified regex for get_name method (#10)

* [feat] added tests for get_name (REQ_003) (#12)

* [feat] added tests for replace_global function (REQ_005) (#12)

* [feat] added tests for extract_headers function (REQ_003) (#12)

* [fix] fixed the structure of split_requests function (#12)

* [refactor] unnested the inner function of http_parser (#12)

* [feat] added tests for parse_single_request (REQ_002) (#12)

* [fix] changes to files to enforce code style (#14)

* [fix] additional fixes for code style enforcement

* [fix] more fixes for code style enforcement (#14)
* [dev] adds the functionality of resolving dependencies (#17)

* [dev] Modifies dependencies tests to be in line with new functionality (#12)

* [dev] added requirements to run

* [refactor] Make types usable for python version < 3.9 and refactor code to be in accordance with the style guide

* [refactor] remove unused imports, updated style of http parser tests

* [fix] replaced tuple by Tuple

* [fix] incorrect return types used

* [doc] document replace_dependencies
Extended implementation of the parser
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.

5 participants