The goal of this feature is to improve the process of sending requests in Playwright and help avoid repeating steps in the test file. Currently, the handler includes variables and methods for sending requests using the HTTP methods GET, PUT, POST, and DELETE. The handler is initialized via the apiFixture.ts file in the Fixtures folder. It initializes the RequestHanlder class, and when we need to send a request, we add the fixture to the tests section. The new getRequest, postRequest, putRequest, and deleteRequest methods are based on Playwright's request fixture mechanism, but they simply add a more convenient wrapper for the request itself, then convert the response to JSON format and check the response status code. The result is a single, convenient way to send the request.
