Skip to content
New issue

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

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

Already on GitHub? # to your account

Create an integration test for /share endpoint #28

Open
anatoly-scherbakov opened this issue Oct 31, 2021 · 0 comments
Open

Create an integration test for /share endpoint #28

anatoly-scherbakov opened this issue Oct 31, 2021 · 0 comments

Comments

@anatoly-scherbakov
Copy link
Owner

Create a Python package named tests. In there, write a simple test function that will be executed by running pytest tests. For that, it will be necessary to poetry add --dev pytest.

In the test, it is necessary to use boto3 to access the S3 bucket and to use requests to call the API endpoint.

  • call the /share endpoint with requests to save a file for a random phrase in PNG format onto S3 bucket,
  • access the file location on S3 via boto3,
  • and verify that the file exists.
RomanZorkin added a commit to RomanZorkin/geopatterns-demo that referenced this issue Nov 2, 2021
Create an integration test for /share endpoint anatoly-scherbakov#28
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant