#Writing test code for a function

1 messages · Page 1 of 1 (latest)

blissful sage
#

Hi, I am writing a function that will use AWS S3's UploadPart API and hopefully contribute it to the s3 library, so far the function is working fine. I am having trouble designing a test for it as it will only accept a payload of minumum 5mb to be uploaded as a file part(AWS side requirement). Would generating a 5mb file within the test itself and using it be a good idea, especially in automated tests and such... ?

UploadPart : https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPart.html

autumn lodge