This PR adds tests to the main.py file using the mocker fixture from pytest-mock. The tests cover the initialization and forward method of the Net class, as well as the integration of the Net class with the FastAPI app in the api.py file.
Summary of Changes
Created a new file named test_main.py in the src directory.
Imported the necessary modules for testing, including pytest, pytest-mock, and modules from main.py and api.py.
Added test functions to check the initialization of the Net class, the forward method of the Net class, and the integration of the Net class with the FastAPI app.
Used the mocker fixture to mock relevant objects and methods in the tests.
Ensured that the tests cover the functionality of the model and its integration with the API.
Please review and merge this PR. Thank you!
Fixes #10.
š Latest improvements to Sweep:
Sweep can now passively improve your repository! Check out Rules to learn more.
š” To get Sweep to edit this pull request, you can:
Comment below, and Sweep can edit the entire PR
Comment on a file, Sweep will only modify the commented file
Edit the original issue to get Sweep to recreate the PR from scratch
Description
This PR adds tests to the main.py file using the mocker fixture from pytest-mock. The tests cover the initialization and forward method of the Net class, as well as the integration of the Net class with the FastAPI app in the api.py file.
Summary of Changes
Please review and merge this PR. Thank you!
Fixes #10.
š Latest improvements to Sweep:
š” To get Sweep to edit this pull request, you can: